/* ==========================================================================
   Util Monster - Common Styles
   ========================================================================== */

/* Base Reset
   ========================================================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Body & Typography
   ========================================================================== */
body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, 'Malgun Gothic', 'Apple SD Gothic Neo', sans-serif;
    background: #f8fafc;
    min-height: 100vh;
    /* padding-top removed - using sticky top-bar instead of fixed */
}

/* Navigation Bar
   ========================================================================== */
.nav-bar {
    background: white;
    padding: 15px 20px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
    display: flex;
    gap: 10px;
    align-items: center;
}

body.dark-mode .nav-bar {
    background: #2d3748;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

/* Hero Section
   ========================================================================== */
.hero-section {
    background: linear-gradient(135deg, #06b6d4 0%, #0891b2 100%);
    padding: 30px 20px;
    text-align: center;
    color: white;
}

.hero-section h1 {
    color: white;
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 12px;
}

.hero-section .subtitle {
    font-size: 16px;
    margin-bottom: 12px;
    opacity: 0.95;
    line-height: 1.5;
}

.hero-section .purpose {
    font-size: 15px;
    max-width: 800px;
    margin: 0 auto;
    opacity: 0.95;
    line-height: 1.5;
}

body.dark-mode .hero-section {
    background: linear-gradient(135deg, #2d3748 0%, #1a202c 100%);
}

/* Container & Layout
   ========================================================================== */
.container {
    background: #f8fafc;
    padding: 0;
}

.content-wrapper {
    max-width: 1400px;
    margin: 0 auto;
    padding: 30px 20px;
}

body.dark-mode .container {
    background: #1a202c;
}

/* Form Elements
   ========================================================================== */
input[type="number"],
input[type="text"],
input[type="email"],
select,
textarea {
    padding: 10px 12px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 15px;
    width: 100%;
    transition: all 0.3s;
}

input[type="number"]:focus,
input[type="text"]:focus,
input[type="email"]:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: #06b6d4;
    box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.1);
}

label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #4a5568;
    margin-bottom: 6px;
}

body.dark-mode input[type="number"],
body.dark-mode input[type="text"],
body.dark-mode input[type="email"],
body.dark-mode select,
body.dark-mode textarea {
    background: #2d3748;
    border-color: #4a5568;
    color: #e8e8e8;
}

body.dark-mode label {
    color: #cbd5e0;
}

/* Buttons
   ========================================================================== */
button {
    padding: 10px 20px;
    background: #06b6d4;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

button:hover {
    background: #0891b2;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(6, 182, 212, 0.3);
}

button:active {
    transform: translateY(0);
}

/* Dark Mode Body
   ========================================================================== */
body.dark-mode {
    background: #1a202c;
    color: #e8e8e8;
}

/* Footer
   ========================================================================== */
.footer {
    background: linear-gradient(135deg, #06b6d4 0%, #0891b2 100%);
    text-align: center;
    padding: 30px 20px;
    color: white;
    font-size: 14px;
}

.footer p {
    margin: 5px 0;
}

/* Responsive Design
   ========================================================================== */
@media (max-width: 768px) {
    .hero-section {
        padding: 25px 20px;
    }

    .hero-section h1 {
        font-size: 24px;
    }

    .hero-section .subtitle {
        font-size: 14px;
    }

    .content-wrapper {
        padding: 30px 15px;
    }

    .nav-bar {
        flex-wrap: wrap;
        padding: 12px 15px;
    }
}

@media (max-width: 480px) {
    .hero-section h1 {
        font-size: 22px;
    }

    .hero-section .subtitle {
        font-size: 13px;
    }
}

/* Top Bar Component
   ========================================================================== */
.top-bar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 60px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 30px;
    z-index: 1000;
}

body.dark-mode .top-bar {
    background: rgba(30, 41, 59, 0.95);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

/* Brand Logo in Top Bar
   ========================================================================== */
.brand-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: #1e293b;
    font-weight: 700;
    font-size: 18px;
    transition: all 0.3s;
}

.brand-logo:hover {
    color: #06b6d4;
    transform: translateY(-1px);
}

.brand-icon {
    font-size: 28px;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.brand-name {
    font-size: 20px;
    letter-spacing: -0.5px;
}

body.dark-mode .brand-logo {
    color: #06b6d4;
}

body.dark-mode .brand-logo:hover {
    color: #22d3ee;
}

.top-bar-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.language-selector-wrapper {
    position: static;
}

.language-selector-wrapper > div {
    position: static !important;
    box-shadow: none !important;
}

.language-selector-wrapper select {
    border: 2px solid rgba(6, 182, 212, 0.3) !important;
    box-shadow: none !important;
}

.language-selector-wrapper select:hover {
    border-color: #06b6d4 !important;
}

/* Dark Mode Toggle - Modern Switch Design
   ========================================================================== */
.dark-mode-toggle {
    display: flex;
    align-items: center;
}

.toggle-switch {
    position: relative;
    width: 70px;
    height: 34px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    border: 2px solid rgba(6, 182, 212, 0.2);
    backdrop-filter: blur(10px);
}

.toggle-switch:hover {
    box-shadow: 0 6px 16px rgba(6, 182, 212, 0.3);
    border-color: #06b6d4;
}

.toggle-slider {
    position: absolute;
    top: 3px;
    left: 4px;
    width: 26px;
    height: 26px;
    background: white;
    border-radius: 50%;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
}

.toggle-slider::before {
    content: '☀️';
    filter: drop-shadow(0 0 2px rgba(251, 191, 36, 0.5));
}

body.dark-mode .toggle-switch {
    background: rgba(30, 41, 59, 0.9);
    border-color: rgba(6, 182, 212, 0.4);
}

body.dark-mode .toggle-slider {
    left: 38px;
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
}

body.dark-mode .toggle-slider::before {
    content: '🌙';
}

/* Utility Classes
   ========================================================================== */
.text-center {
    text-align: center;
}

.mb-20 {
    margin-bottom: 20px;
}

.mt-20 {
    margin-top: 20px;
}

/* Responsive Adjustments for Top Bar
   ========================================================================== */
@media (max-width: 768px) {
    .top-bar {
        height: 50px;
        padding: 0 15px;
    }

    .brand-logo {
        font-size: 16px;
        gap: 8px;
    }

    .brand-icon {
        font-size: 24px;
    }

    .brand-name {
        font-size: 16px;
    }

    .top-bar-right {
        gap: 12px;
    }

    .toggle-switch {
        width: 60px;
        height: 30px;
    }

    .toggle-slider {
        width: 22px;
        height: 22px;
        font-size: 12px;
    }

    body.dark-mode .toggle-slider {
        left: 33px;
    }

    .language-selector-wrapper select {
        padding: 6px 12px !important;
        font-size: 13px !important;
    }
}

@media (max-width: 480px) {
    .brand-name {
        display: none;
    }

    .top-bar-right {
        gap: 10px;
    }
}
