/* ==========================================================================
   Caltohub.com - Modern Dark/Light Glassmorphism Fitness Calculator CSS System
   ========================================================================== */

:root {
    --bg-main: #0F172A;
    --bg-card: rgba(30, 41, 59, 0.75);
    --bg-card-hover: rgba(51, 65, 85, 0.85);
    --border-color: rgba(255, 255, 255, 0.1);
    
    --primary: #43A047;
    --primary-hover: #2E7D32;
    --primary-glow: rgba(67, 160, 71, 0.3);

    --accent-blue: #3B82F6;
    --accent-purple: #8B5CF6;
    --accent-amber: #F59E0B;
    
    --text-main: #F8FAFC;
    --text-muted: #94A3B8;
    --text-dim: #64748B;

    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --shadow-main: 0 20px 40px -15px rgba(0, 0, 0, 0.5);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

body {
    background-color: var(--bg-main);
    color: var(--text-main);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background-image: 
        radial-gradient(circle at 10% 20%, rgba(59, 130, 246, 0.12) 0%, transparent 40%),
        radial-gradient(circle at 90% 80%, rgba(67, 160, 71, 0.12) 0%, transparent 40%);
}

/* Header Navigation */
.header-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 2rem;
    background: rgba(15, 23, 42, 0.9);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 100;
    gap: 1rem;
}

.brand-box {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    flex-shrink: 0;
}

/* Double Sized Logo (70px sleek) */
.brand-logo-img {
    height: 70px;
    width: auto;
    object-fit: contain;
    background: transparent !important;
    padding: 0 !important;
    box-shadow: none !important;
    border-radius: 0;
    filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.5));
    transition: transform 0.2s ease;
}

.brand-logo-img:hover {
    transform: scale(1.05);
}

.brand-badge {
    background: rgba(67, 160, 71, 0.15);
    color: #81C784;
    border: 1px solid rgba(67, 160, 71, 0.3);
    font-size: 0.75rem;
    padding: 3px 10px;
    border-radius: 16px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.nav-links {
    display: flex;
    gap: 0.4rem;
    list-style: none;
    align-items: center;
    flex-wrap: wrap;
    justify-content: center;
}

.nav-link {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.82rem;
    font-weight: 600;
    letter-spacing: 0.2px;
    padding: 6px 12px;
    border-radius: 20px;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.nav-link:hover, .nav-link.active {
    color: var(--text-main);
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
}

/* Container */
.main-container {
    max-width: 1100px;
    width: 90%;
    margin: 2.5rem auto;
    flex: 1;
}

/* Ad Slot Placeholder & Responsive Banner Box */
.ad-slot {
    background: rgba(255, 255, 255, 0.04);
    border: 1px dashed rgba(255, 255, 255, 0.2);
    border-radius: var(--radius-md);
    padding: 1rem;
    margin: 2rem 0;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.85rem;
    min-height: 100px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(8px);
}

.ad-slot::before {
    content: "📢 ADVERTISEMENT (Google AdSense Space)";
    display: block;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--primary);
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
    opacity: 0.85;
}

/* Hero Title */
.hero-title {
    font-size: 2.6rem;
    font-weight: 800;
    text-align: center;
    margin-bottom: 0.5rem;
    background: linear-gradient(135deg, #FFFFFF 30%, #81C784 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-transform: uppercase;
    letter-spacing: -0.5px;
}

.hero-subtitle {
    text-align: center;
    color: var(--text-muted);
    max-width: 650px;
    margin: 0 auto 2.5rem;
    font-size: 1.05rem;
    line-height: 1.5;
}

/* Calculator Tabs Navigation */
.calc-tabs {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.tab-btn {
    background: rgba(30, 41, 59, 0.6);
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius-md);
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.tab-btn:hover, .tab-btn.active {
    background: rgba(67, 160, 71, 0.2);
    border-color: var(--primary);
    color: var(--text-main);
    box-shadow: 0 4px 15px rgba(67, 160, 71, 0.3);
}

/* Calculator Card & Layout */
.calc-card {
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 2.25rem;
    box-shadow: var(--shadow-main);
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
}

@media (max-width: 768px) {
    .calc-card {
        grid-template-columns: 1fr;
    }
}

.form-group {
    margin-bottom: 1.25rem;
}

.form-label {
    display: block;
    font-size: 0.9rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #E2E8F0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.input-row {
    display: flex;
    gap: 0.75rem;
}

.form-input, .form-select {
    width: 100%;
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 0.85rem 1rem;
    color: var(--text-main);
    font-size: 1rem;
    outline: none;
    transition: border-color 0.2s ease;
}

.form-input:focus, .form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 15px var(--primary-glow);
}

.form-select option {
    background: #0F172A;
    color: #FFF;
}

.gender-toggle {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
}

.gender-btn {
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    padding: 0.75rem;
    border-radius: var(--radius-md);
    cursor: pointer;
    font-weight: 700;
    text-align: center;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.gender-btn.active {
    background: rgba(59, 130, 246, 0.2);
    border-color: var(--accent-blue);
    color: white;
}

.btn-calc {
    width: 100%;
    background: linear-gradient(135deg, var(--primary), var(--primary-hover));
    color: white;
    font-weight: 800;
    font-size: 1.05rem;
    padding: 1rem;
    border-radius: var(--radius-md);
    border: none;
    cursor: pointer;
    margin-top: 1rem;
    box-shadow: 0 4px 15px rgba(67, 160, 71, 0.3);
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-calc:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(67, 160, 71, 0.5);
}

/* Result Box Display */
.result-box {
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 1.75rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    text-align: center;
}

.result-val {
    font-size: 3.5rem;
    font-weight: 800;
    color: #81C784;
    margin: 0.5rem 0;
    line-height: 1;
}

.result-status {
    display: inline-block;
    font-weight: 800;
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 0.95rem;
    margin: 0.5rem auto 1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.status-normal { background: rgba(67, 160, 71, 0.2); color: #81C784; border: 1px solid rgba(67, 160, 71, 0.4); }
.status-warn { background: rgba(245, 158, 11, 0.2); color: #FCD34D; border: 1px solid rgba(245, 158, 11, 0.4); }
.status-danger { background: rgba(239, 68, 68, 0.2); color: #FCA5A5; border: 1px solid rgba(239, 68, 68, 0.4); }

.result-desc {
    color: var(--text-muted);
    font-size: 0.92rem;
    line-height: 1.5;
}

/* Educational Content Cards Section */
.article-section {
    margin-top: 4rem;
}

.article-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 2rem;
    margin-bottom: 2rem;
    line-height: 1.7;
    color: #CBD5E1;
}

.article-card h2 {
    color: var(--text-main);
    font-size: 1.4rem;
    margin-bottom: 1rem;
    border-left: 4px solid var(--primary);
    padding-left: 0.75rem;
}

.article-card h3 {
    color: var(--text-main);
    font-size: 1.15rem;
    margin: 1.5rem 0 0.75rem;
}

.article-card p {
    margin-bottom: 1rem;
}

.article-card ul {
    margin-left: 1.5rem;
    margin-bottom: 1rem;
}

.article-card table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.25rem 0;
    font-size: 0.9rem;
}

.article-card th, .article-card td {
    padding: 0.75rem 1rem;
    border: 1px solid var(--border-color);
    text-align: left;
}

.article-card th {
    background: rgba(15, 23, 42, 0.8);
    color: var(--text-main);
    font-weight: 700;
}

.article-card tr:nth-child(even) {
    background: rgba(255, 255, 255, 0.02);
}

.formula-box {
    background: rgba(15, 23, 42, 0.7);
    border: 1px solid var(--border-color);
    border-left: 4px solid #60A5FA;
    padding: 1.25rem;
    border-radius: var(--radius-sm);
    font-family: SFMono-Regular, Consolas, 'Liberation Mono', Menlo, monospace;
    font-size: 0.9rem;
    line-height: 1.6;
    margin: 1.25rem 0;
    color: #E2E8F0;
}

.formula-box-ecom {
    border-left-color: #4ADE80;
}


/* Footer & Disclaimer */
footer {
    background: rgba(15, 23, 42, 0.9);
    border-top: 1px solid var(--border-color);
    padding: 2.5rem 0;
    margin-top: 4rem;
    text-align: center;
    font-size: 0.9rem;
    color: var(--text-dim);
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-bottom: 1.25rem;
}

.footer-link {
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: color 0.2s ease;
}

.footer-link:hover {
    color: var(--text-main);
}

.medical-disclaimer {
    max-width: 800px;
    margin: 1.5rem auto 0;
    font-size: 0.8rem;
    color: var(--text-dim);
    line-height: 1.5;
}

/* ==========================================================================
   New Form Controls & Multi-Calculator Components
   ========================================================================== */

.form-row-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.form-textarea {
    width: 100%;
    background: rgba(15, 23, 42, 0.7);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-main);
    padding: 0.75rem 1rem;
    font-size: 0.95rem;
    resize: vertical;
    transition: all 0.2s ease;
}

.form-textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-glow);
}

.res-stat-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
    margin: 1.25rem 0;
}

.stat-card {
    background: rgba(15, 23, 42, 0.5);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 0.75rem;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.stat-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.25rem;
}

.stat-val {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-main);
}

/* AI Model Comparison Table / List */
.comparison-container {
    margin-top: 1.5rem;
    border-top: 1px solid var(--border-color);
    padding-top: 1rem;
}

.comparison-title {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.75rem;
}

.comparison-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.comp-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 0.5rem 0.75rem;
    font-size: 0.85rem;
    transition: background 0.2s ease;
}

.comp-item.active-model {
    border-color: #60A5FA;
    background: rgba(59, 130, 246, 0.15);
}

.comp-name {
    font-weight: 600;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.comp-badge {
    font-size: 0.7rem;
    padding: 2px 6px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-muted);
}

.comp-cost {
    font-weight: 700;
    color: #60A5FA;
}

/* E-Commerce Cost Breakdown Bars */
.cost-breakdown-box {
    margin-top: 1.5rem;
    border-top: 1px solid var(--border-color);
    padding-top: 1rem;
}

.breakdown-title {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.75rem;
}

.cost-bars-container {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.cost-bar-item {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.cost-bar-header {
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
    color: var(--text-muted);
}

.cost-bar-track {
    height: 8px;
    background: rgba(15, 23, 42, 0.8);
    border-radius: 4px;
    overflow: hidden;
}

.cost-bar-fill {
    height: 100%;
    border-radius: 4px;
    transition: width 0.3s ease;
}

@media (max-width: 640px) {
    .form-row-2 {
        grid-template-columns: 1fr;
    }
    .calc-tabs {
        flex-wrap: wrap;
    }
}

/* ==========================================================================
   Freelance Calculator Quote Summary Card Styles
   ========================================================================== */

.form-hint {
    display: block;
    font-size: 0.75rem;
    color: var(--text-dim);
    margin-top: 0.25rem;
}

.quote-card-preview {
    margin-top: 1.5rem;
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.9) 0%, rgba(30, 41, 59, 0.9) 100%);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 1.25rem;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.5);
    position: relative;
    overflow: hidden;
}

.quote-card-preview::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(to bottom, #4ADE80, #3B82F6);
}

.quote-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px dashed var(--border-color);
    padding-bottom: 0.75rem;
    margin-bottom: 0.75rem;
}

.quote-badge {
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 1px;
    background: rgba(74, 222, 128, 0.15);
    color: #4ADE80;
    border: 1px solid rgba(74, 222, 128, 0.3);
    padding: 3px 8px;
    border-radius: 4px;
}

.quote-amount {
    font-size: 1.4rem;
    font-weight: 800;
    color: #4ADE80;
}

.quote-details {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    font-size: 0.85rem;
}

.quote-row {
    display: flex;
    justify-content: space-between;
    color: var(--text-muted);
}

/* ==========================================================================
   Header Language Switcher Dropdown (i18n)
   ========================================================================== */

.lang-switcher {
    position: relative;
    display: inline-block;
}

.lang-btn {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid var(--border-color);
    color: var(--text-main);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    transition: all 0.2s ease;
    user-select: none;
}

.lang-btn:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.3);
}

.lang-dropdown {
    position: absolute;
    right: 0;
    top: 100%;
    margin-top: 4px;
    background: rgba(15, 23, 42, 0.98);
    backdrop-filter: blur(16px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.8);
    min-width: 160px;
    display: none;
    flex-direction: column;
    z-index: 999;
    overflow: hidden;
    pointer-events: auto;
}

/* Invisible bridge pseudo-element so mouse hover never drops */
.lang-dropdown::before {
    content: "";
    position: absolute;
    top: -10px;
    left: 0;
    width: 100%;
    height: 10px;
}

.lang-switcher:hover .lang-dropdown,
.lang-dropdown.active {
    display: flex !important;
}

.lang-dropdown a {
    color: var(--text-muted);
    text-decoration: none;
    padding: 10px 14px;
    font-size: 0.85rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: background 0.2s ease, color 0.2s ease;
    cursor: pointer;
}

.lang-dropdown a:hover {
    background: rgba(59, 130, 246, 0.25);
    color: var(--text-main);
}



