/* 
 * DESIGN SYSTEM (MANIFEST)
 * - Font: System (SF / Roboto)
 * - Radius: 16px
 * - Shadow: Soft (0 10px 30px rgba(0,0,0,0.05))
 * - Colors: BG #F7F9FC, Accent #34C759, Text #2D3436
 */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --bg-color: #F7F9FC;
    --card-bg: #FFFFFF;
    --accent-green: #34C759;
    --accent-green-hover: #2DA84E;
    --accent-blue: #007AFF;
    --text-primary: #2D3436;
    --text-secondary: #636E72;
    --border-color: #DFE6E9;
    --font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    --radius: 16px;
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    --header-height: 80px;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-family);
    background-color: var(--bg-color);
    color: var(--text-primary);
    min-height: 100vh;
    line-height: 1.5;
    padding-top: var(--header-height);
}

/* Utility */
.hidden {
    display: none !important;
}

.container {
    width: 100%;
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
}

/* BUTTONS */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 28px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 20px;
    cursor: pointer;
    border: none;
    transition: all 0.2s ease;
    text-align: center;
    letter-spacing: 0.3px;
}

.btn:active {
    transform: scale(0.98);
}

.btn-green {
    background-color: var(--accent-green);
    color: white;
    box-shadow: 0 4px 12px rgba(52, 199, 89, 0.2);
}

.btn-green:hover {
    background-color: var(--accent-green-hover);
    box-shadow: 0 6px 16px rgba(52, 199, 89, 0.3);
}

.btn-blue {
    background-color: var(--accent-blue);
    color: white;
    box-shadow: 0 4px 12px rgba(0, 122, 255, 0.2);
}

.btn-blue:hover {
    opacity: 0.9;
    box-shadow: 0 6px 16px rgba(0, 122, 255, 0.3);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--border-color);
    color: var(--text-primary);
    padding: 12px 24px;
}

.btn-outline:hover {
    border-color: var(--text-primary);
    background: rgba(0, 0, 0, 0.02);
}

.btn-large {
    padding: 18px 36px;
    font-size: 18px;
    border-radius: 24px;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 14px;
    border-radius: 14px;
}

/* HEADER */
.site-header {
    height: var(--header-height);
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.05);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    height: 100%;
}

.logo {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-primary);
    text-decoration: none;
    letter-spacing: -0.5px;
}

.logo span {
    color: var(--accent-green);
}

.main-nav {
    display: flex;
    gap: 32px;
}

.main-nav a {
    text-decoration: none;
    color: #4a5568;
    font-size: 16px;
    font-weight: 500;
    transition: color 0.2s;
}

.main-nav a:hover {
    color: var(--accent-green);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 15px;
    /* Added gap for actions */
}

/* Hide Nav on Mobile */
@media (max-width: 768px) {
    .main-nav {
        display: none;
    }
}

/* HERO SECTION */
.hero {
    height: 100vh;
    min-height: 600px;
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)), url('assets/images/hero_bg.png');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
    padding-top: var(--header-height);
}

.hero h1 {
    font-size: 64px;
    font-weight: 900;
    line-height: 1.1;
    margin-bottom: 20px;
    letter-spacing: -2px;
    color: white;
    -webkit-text-fill-color: white;
    background: none;
}

.hero p {
    font-size: 24px;
    color: rgba(255, 255, 255, 0.9);
    max-width: 700px;
    margin: 0 auto 40px;
    font-weight: 400;
}

/* FEATURES */
.features-section {
    padding: 100px 0;
    background: #f8f9fa;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.feature-item {
    background: white;
    padding: 40px;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid rgba(0, 0, 0, 0.02);
}

.feature-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.feature-icon {
    font-size: 48px;
    margin-bottom: 20px;
    display: block;
}

.feature-item h3 {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 15px;
    color: var(--text-primary);
}

.feature-item p {
    font-size: 16px;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* MOTIVATION */
.motivation-section {
    padding: 120px 20px;
    background: linear-gradient(135deg, #fdfbfb 0%, #ebedee 100%);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.quote {
    font-size: 32px;
    font-weight: 600;
    font-style: italic;
    color: #2D3436;
    max-width: 900px;
    margin: 0 auto 30px;
    line-height: 1.4;
    position: relative;
    z-index: 1;
}

.quote::before {
    content: "“";
    font-size: 120px;
    color: rgba(0, 0, 0, 0.05);
    position: absolute;
    top: -60px;
    left: -40px;
    font-family: serif;
    z-index: -1;
}

.quote-author {
    color: var(--text-primary);
    font-size: 18px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    opacity: 0.7;
}

/* CARD STYLES */
.card {
    background: var(--card-bg);
    padding: 40px;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    margin-bottom: 30px;
    border: 1px solid rgba(0, 0, 0, 0.02);
}

h2 {
    font-size: 28px;
    margin-bottom: 25px;
    font-weight: 800;
    letter-spacing: -0.5px;
}

h3 {
    font-size: 20px;
    margin-bottom: 15px;
    font-weight: 700;
}

/* FORMS */
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

.form-group {
    margin-bottom: 20px;
}

label {
    display: block;
    margin-bottom: 10px;
    font-weight: 600;
    font-size: 14px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

input[type="number"],
select,
input[type="text"],
input[type="password"] {
    width: 100%;
    padding: 16px;
    font-size: 16px;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    background: #FDFDFD;
    transition: all 0.2s ease;
    -webkit-appearance: none;
    color: var(--text-primary);
    font-weight: 500;
}

input:focus,
select:focus {
    border-color: var(--accent-green);
    outline: none;
    background: #fff;
    box-shadow: 0 0 0 4px rgba(52, 199, 89, 0.1);
}

input::placeholder {
    color: #B2BEC3;
}

/* GENDER TOGGLE */
.gender-toggle {
    display: flex;
    background: #F1F3F5;
    padding: 5px;
    border-radius: 14px;
}

.gender-toggle input {
    display: none;
}

.gender-toggle label {
    flex: 1;
    text-align: center;
    padding: 14px;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 700;
    color: var(--text-secondary);
    transition: 0.2s;
}

.gender-toggle input:checked+label {
    background: white;
    color: var(--text-primary);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

/* CHECKBOX & ACTIVITY */
.checkbox-wrapper {
    display: flex;
    align-items: center;
    cursor: pointer;
    margin-bottom: 15px;
}

.checkbox-wrapper input {
    width: 22px;
    height: 22px;
    margin-right: 12px;
    accent-color: var(--accent-green);
    cursor: pointer;
}

.checkbox-wrapper span {
    font-weight: 500;
    color: var(--text-primary);
}

/* RESULTS GRID */
.results-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 40px;
    margin-bottom: 30px;
}

.result-card {
    background: #FAFAFA;
    border-radius: var(--radius);
    padding: 25px;
    text-align: center;
    border: 2px solid transparent;
    transition: transform 0.2s;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.result-card:hover {
    transform: translateY(-3px);
}

.result-card.main {
    background: rgba(52, 199, 89, 0.08);
    border-color: var(--accent-green);
}

.res-title {
    font-size: 13px;
    text-transform: uppercase;
    color: var(--text-secondary);
    font-weight: 700;
    margin-bottom: 8px;
    letter-spacing: 0.5px;
}

.res-val {
    font-size: 32px;
    font-weight: 800;
    color: var(--text-primary);
    line-height: 1.2;
}

.res-unit {
    font-size: 13px;
    color: var(--text-secondary);
    font-weight: 500;
    margin-top: 5px;
}

.res-kj {
    font-size: 12px;
    color: #B2BEC3;
    margin-top: 2px;
    margin-bottom: 15px;
}

/* Macros */
.res-macros {
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    padding-top: 15px;
    font-size: 12px;
    color: var(--text-secondary);
    display: flex;
    justify-content: space-between;
}

.res-macros div {
    display: flex;
    flex-direction: column;
}

.res-macros span {
    font-weight: 700;
    color: var(--text-primary);
}

/* GOAL PROJECTION */
.goal-projection {
    background: linear-gradient(135deg, #007AFF 0%, #0056B3 100%);
    color: white;
    padding: 20px;
    border-radius: var(--radius);
    margin-bottom: 30px;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    box-shadow: 0 10px 30px rgba(0, 122, 255, 0.2);
}

.goal-date {
    font-weight: 800;
    font-size: 18px;
    background: rgba(255, 255, 255, 0.2);
    padding: 5px 15px;
    border-radius: 20px;
}

/* CTA BLOCKS */
.guest-cta {
    background: linear-gradient(135deg, #2D3436 0%, #000000 100%);
    color: white;
    padding: 50px 30px;
    border-radius: var(--radius);
    text-align: center;
    margin-top: 20px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15);
}

.guest-cta h3 {
    color: white;
    margin-bottom: 15px;
    font-size: 26px;
}

.guest-cta p {
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 30px;
    font-size: 18px;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

/* USER ACTIONS */
.user-actions {
    margin-top: 20px;
    padding: 25px;
    border-radius: var(--radius);
    background: white;
    border: 1px solid var(--border-color);
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    align-items: center;
    justify-content: space-between;
}

/* PROGRESS SECTION */
.progress-section {
    margin-top: 60px;
    padding-top: 40px;
    border-top: 2px solid #F1F3F5;
}

.chart-wrap {
    height: 350px;
    margin-top: 25px;
    background: white;
    padding: 20px;
    border-radius: var(--radius);
    border: 2px solid var(--border-color);
}

/* ADMIN PANEL */
.admin-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
    border-radius: 12px;
    overflow: hidden;
    margin-top: 30px;
}

.admin-table th,
.admin-table td {
    padding: 15px 20px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

.role-form {
    display: flex;
    align-items: center;
    gap: 10px;
}

.role-select {
    width: auto !important;
    margin: 0 !important;
    padding: 8px 12px !important;
    font-size: 14px !important;
}

.history-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    margin-top: 30px;
}

.history-table th,
.history-table td {
    padding: 16px;
    text-align: left;
    border-bottom: 1px solid #F1F3F5;
}

.history-table th {
    font-weight: 700;
    color: var(--text-secondary);
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 0.5px;
}

.history-table tr:last-child td {
    border-bottom: none;
}

/* SETTINGS BLOCK */
.settings-block {
    margin-top: 60px;
    padding: 30px;
    background: #F1F3F5;
    border-radius: var(--radius);
}

.settings-actions {
    display: flex;
    gap: 15px;
    margin-top: 15px;
    flex-wrap: wrap;
}

/* MODALS */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(45, 52, 54, 0.6);
    backdrop-filter: blur(8px);
    z-index: 1000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: 0.3s;
}

.modal-overlay.open {
    opacity: 1;
    visibility: visible;
}

.modal {
    background: white;
    width: 100%;
    max-width: 440px;
    padding: 40px;
    border-radius: 24px;
    transform: scale(0.95);
    transition: 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.2);
    position: relative;
}

.modal-overlay.open .modal {
    transform: scale(1);
}

.close-modal {
    position: absolute;
    top: 20px;
    right: 20px;
    background: none;
    border: none;
    font-size: 28px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: 0.2s;
}

.close-modal:hover {
    color: var(--text-primary);
    transform: rotate(90deg);
}

.switch-auth {
    text-align: center;
    margin-top: 25px;
    font-size: 15px;
    color: var(--text-secondary);
}

.switch-auth span {
    color: var(--accent-green);
    cursor: pointer;
    font-weight: 700;
}

@media (max-width: 768px) {
    .hero h1 {
        font-size: 38px;
    }

    .features-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .quote {
        font-size: 24px;
    }

    .results-grid {
        grid-template-columns: 1fr;
    }

    .form-row {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .card {
        padding: 25px;
    }

    .goal-projection {
        flex-direction: column;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 30px;
        text-align: center;
    }

    .footer-col {
        align-items: center;
    }

    .sub-footer {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
}

/* TOAST NOTIFICATIONS */
#toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.toast {
    background: white;
    padding: 16px 24px;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 300px;
}

/* WATER WIDGET */
.water-widget {
    background: linear-gradient(135deg, #fdfbfb 0%, #ebedee 100%);
    border: 1px solid var(--border-color);
}

.water-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.water-body {
    display: flex;
    align-items: center;
    justify-content: space-around;
    flex-wrap: wrap;
    gap: 20px;
}

.water-progress-wrap {
    position: relative;
    width: 120px;
    height: 120px;
}

.progress-ring__circle {
    transition: stroke-dashoffset 0.8s ease-in-out;
    transform: rotate(-90deg);
    transform-origin: 50% 50%;
    stroke-dasharray: 326.72;
    /* 2 * PI * 52 */
    stroke-dashoffset: 326.72;
    stroke-linecap: round;
}

.water-value {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    display: flex;
    flex-direction: column;
}

#water-current {
    font-size: 22px;
    font-weight: 800;
    color: #2c3e50;
}

.water-target {
    font-size: 12px;
    color: #7f8c8d;
}

.water-controls {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.btn-water {
    background: white;
    border: 1px solid #3498db;
    color: #2980b9;
    padding: 10px 20px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-water:hover {
    background: #ebf5fb;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(52, 152, 219, 0.2);
}

.btn-icon-small {
    background: none;
    border: none;
    font-size: 18px;
    cursor: pointer;
    opacity: 0.5;
    transition: 0.2s;
}

.btn-icon-small:hover {
    opacity: 1;
    transform: rotate(180deg);
}

animation: slideIn 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
border-left: 5px solid #ccc;
}

.toast-success {
    border-left-color: var(--accent-green);
}

.toast-error {
    border-left-color: #FF3B30;
}

.toast-info {
    border-left-color: var(--accent-blue);
}

.toast-message {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(50px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeOut {
    to {
        opacity: 0;
        transform: translateY(-10px);
    }
}

/* CUSTOM MODAL OVERRIDES */
/* Re-using .modal structure but adding specific IDs for general use */
#custom-modal-title {
    margin-top: 0;
    text-align: center;
}

#custom-modal-message {
    text-align: center;
    color: var(--text-secondary);
    margin-bottom: 30px;
}

.modal-actions {
    display: flex;
    justify-content: center;
    gap: 15px;
}

/* FOOTER */
.site-footer {
    background: #2D3436;
    color: white;
    padding: 80px 0 40px;
    margin-top: auto;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 60px;
}

.footer-col {
    display: flex;
    flex-direction: column;
}

.footer-logo {
    font-size: 24px;
    font-weight: 800;
    margin-bottom: 20px;
    letter-spacing: -0.5px;
}

.footer-logo span {
    color: var(--accent-green);
}

.footer-col p {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.6);
    line-height: 1.6;
    max-width: 250px;
}

.footer-col h4 {
    font-size: 12px;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.4);
    letter-spacing: 1px;
    margin-bottom: 25px;
    font-weight: 700;
}

.footer-col a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    margin-bottom: 15px;
    font-size: 15px;
    transition: 0.2s;
}

.footer-col a:hover {
    color: var(--accent-green);
    transform: translateX(5px);
}

.sub-footer {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 30px;
    color: rgba(255, 255, 255, 0.4);
}

@media (max-width: 768px) {
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 40px;
        text-align: center;
    }

    .footer-col {
        align-items: center;
    }

    .footer-col p {
        margin-left: auto;
        margin-right: auto;
    }
}

/* SECONDARY PAGES */
.page-content {
    max-width: 800px;
    margin: 40px auto;
    padding: 0 20px;
    min-height: 60vh;
}

.page-content-wide {
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 20px;
    width: 100%;
}

.page-content h1,
.page-content-wide h1 {
    font-size: 36px;
    font-weight: 800;
    margin-bottom: 30px;
    text-align: center;
}

.page-content h2,
.page-content-wide h2 {
    font-size: 24px;
    margin-top: 40px;
    margin-bottom: 20px;
}

.page-content p,
.page-content li,
.page-content-wide p,
.page-content-wide li {
    font-size: 16px;
    line-height: 1.8;
    color: var(--text-secondary);
    margin-bottom: 15px;
}

/* PRICING */
.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 50px;
    justify-content: center;
}

.pricing-card {
    background: white;
    padding: 30px 20px;
    border-radius: 20px;
    text-align: center;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(0, 0, 0, 0.02);
    display: flex;
    flex-direction: column;
}

.pricing-card.popular {
    transform: scale(1.05);
    border: 2px solid var(--accent-green);
    position: relative;
    box-shadow: 0 20px 50px rgba(52, 199, 89, 0.15);
}

.popular-tag {
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--accent-green);
    color: white;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
}

.plan-name {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-secondary);
    margin-bottom: 15px;
}

.plan-price {
    display: flex;
    justify-content: center;
    align-items: baseline;
    /* Align currency and amount */
    margin-bottom: 30px;
    color: var(--text-primary);
}

.plan-price .currency {
    font-size: 24px;
    font-weight: 500;
    margin-right: 5px;
    position: relative;
    top: -15px;
    /* Slight lift */
}

.plan-price .amount {
    font-size: 56px;
    font-weight: 800;
    line-height: 1;
}

.plan-price .period {
    font-size: 16px;
    color: var(--text-secondary);
    font-weight: 500;
    margin-left: 5px;
}

.plan-features {
    list-style: none;
    margin-bottom: 40px;
    flex-grow: 1;
    padding: 0;
}

.plan-features li {
    margin-bottom: 15px;
    color: var(--text-secondary);
    font-size: 15px;
    white-space: normal;
    /* Fix text wrapping */
    line-height: 1.5;
}

/* FAQ */
.faq-list {
    margin-top: 40px;
}

.faq-item {
    background: white;
    border-radius: 16px;
    padding: 25px;
    margin-bottom: 20px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.03);
    cursor: pointer;
    transition: 0.2s;
}

.faq-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

.faq-question {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 10px;
    color: var(--text-primary);
}

.faq-answer {
    color: var(--text-secondary);
    line-height: 1.6;
}

.pricing-card.popular {
    transform: scale(1);
}
}

/* HOW IT WORKS */
/* Hero Section */
.hiw-hero {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    width: 100%;
    padding: 80px 20px;
    background-color: var(--bg-color);
}

.hiw-hero h1,
.hiw-hero p {
    text-align: center;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.hiw-hero h1 {
    font-size: 3rem;
    margin-bottom: 16px;
    color: var(--text-primary);
}

/* Steps Grid */
/* Steps Grid */
.steps-grid {
    display: grid;
    grid-template-columns: 1fr;
    /* Mobile Default */
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
    justify-content: center;
}

/* Tablet (2 columns) */
@media (min-width: 768px) {
    .steps-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Desktop (Strict 3 columns) */
@media (min-width: 1024px) {
    .steps-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Step Cards */
.step-card {
    background: #fff;
    padding: 40px;
    border-radius: 24px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease;
    text-align: center;
}

.step-card:hover {
    transform: translateY(-5px);
}

.step-card h3 {
    margin-bottom: 15px;
    font-size: 22px;
}

.step-card p {
    color: var(--text-secondary);
    line-height: 1.6;
}

/* Typography map */
.step-number {
    font-size: 4rem;
    font-weight: 900;
    color: #e2e8f0;
    line-height: 1;
    margin-bottom: -20px;
    display: block;
    position: relative;
    z-index: 0;
}

.step-icon {
    font-size: 3rem;
    margin-bottom: 20px;
    display: block;
    position: relative;
    z-index: 1;
}

/* Science Block */
.science-block {
    background-color: #f8fafc;
    padding: 80px 20px;
    margin-top: 60px;
    border-radius: 32px;
    text-align: center;
}

@media (max-width: 768px) {
    .hiw-hero h1 {
        font-size: 2.5rem;
    }
}

/* ABOUT PAGE */
.values-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 60px;
    justify-content: center;
}

.value-card {
    background: white;
    padding: 40px 30px;
    border-radius: 20px;
    text-align: center;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(0, 0, 0, 0.02);
    transition: transform 0.3s ease;
}

.value-card:hover {
    transform: translateY(-5px);
}

.value-icon {
    font-size: 48px;
    display: block;
    margin-bottom: 20px;
}

.value-card h3 {
    margin-bottom: 15px;
    font-size: 20px;
}

.value-card p {
    color: var(--text-secondary);
    line-height: 1.6;
}

/* CONTACTS PAGE */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    margin-top: 50px;
    align-items: start;
}

.contact-info h3 {
    margin-bottom: 20px;
    font-size: 24px;
}

.contact-info p {
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 30px;
}

.contact-item {
    margin-bottom: 20px;
    font-size: 16px;
}

.contact-item strong {
    display: block;
    margin-bottom: 5px;
    color: var(--text-primary);
}

.contact-item a {
    color: var(--accent-green);
    text-decoration: none;
    font-weight: 500;
}

/* Contact Form */
.contact-form-container {
    background: white;
    padding: 40px;
    border-radius: 24px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.05);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--text-primary);
    font-size: 14px;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 15px;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    font-family: inherit;
    font-size: 16px;
    transition: 0.2s;
    background: #f8fafc;
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--accent-green);
    background: white;
    box-shadow: 0 0 0 3px rgba(52, 199, 89, 0.1);
}

.contact-form textarea {
    resize: vertical;
    min-height: 120px;
}

@media (max-width: 768px) {
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .contact-form-container {
        padding: 25px;
    }
}

/* FASTING WIDGET */
.fasting-widget {
    margin-top: 30px;
    background: white;
    border-radius: 20px;
    padding: 25px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.05);
}

.fasting-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.fasting-header h3 {
    margin: 0;
    font-size: 18px;
    color: var(--text-primary);
}

.fasting-body {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 25px;
}

.fasting-visual {
    position: relative;
    width: 220px;
    height: 220px;
}

.fasting-circle {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: conic-gradient(var(--bg-color) 0deg, var(--bg-color) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    transition: background 0.5s ease;
}

/* Inner white circle to create ring effect */
.fasting-circle::before {
    content: '';
    position: absolute;
    width: 88%;
    height: 88%;
    background: white;
    border-radius: 50%;
    z-index: 1;
}

.fasting-content {
    position: relative;
    z-index: 2;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

#fasting-status-icon {
    font-size: 32px;
    margin-bottom: 5px;
}

#fasting-timer {
    font-size: 36px;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
    color: var(--text-primary);
    line-height: 1.2;
}

.fasting-label {
    font-size: 13px;
    color: var(--text-secondary);
    font-weight: 500;
    margin-top: 5px;
}

/* States */
/* Eating Window */
.fasting-circle.eating {
    background: conic-gradient(var(--accent-green) 0%, var(--bg-color) 0%);
    /* Static ring or just simplified */
    border: 8px solid #E6F4F1;
}

/* Fasting State */
.fasting-circle.fasting {
    /* Background will be set via JS inline for progress */
}

.fasting-controls {
    display: flex;
    gap: 15px;
    width: 100%;
    justify-content: center;
}

.fasting-controls button {
    min-width: 160px;
}