/*
Theme Name: ClearifyMe Modern
Author: Vitin
Description: A minimalist, responsive skincare theme with an AI questionnaire.
Version: 1.6
*/

/* --- 1. Global Resets & Variables --- */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    --primary: #ad8d82;
    /* Earthy Rose */
    --primary-dark: #8e6f64;
    --secondary: #2c3e50;
    /* Deep Navy */
    --bg-light: #faf9f6;
    /* Off-white/Cream */
    --white: #ffffff;
    --text: #333333;
    --text-light: #777777;
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    --transition: all 0.3s ease;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-light);
    color: var(--text);
    line-height: 1.6;
    overflow-x: hidden;
}

/* --- 2. Responsive Header & Navigation (Fixed & Centered) --- */
.site-header {
    background: var(--white);
    padding: 15px 5%;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.03);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1600px;
    margin: 0 auto;
    width: 100%;
}

.logo {
    flex: 1;
    display: flex;
    justify-content: flex-start;
}

.logo a {
    font-weight: 800;
    font-size: 1.4rem;
    text-decoration: none;
    color: var(--secondary);
    letter-spacing: 1px;
}

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

/* The container that holds the menu and auth buttons */
.nav-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex: 2;
    /* Occupies the rest of the header space */
}

.main-nav {
    flex: 2;
    display: flex;
    justify-content: center;
}

.main-nav ul {
    display: flex;
    gap: 30px;
    list-style: none;
    padding: 0;
    margin: 0;
}

.main-nav a {
    text-decoration: none;
    color: var(--text);
    font-weight: 500;
    font-size: 0.95rem;
    transition: var(--transition);
}

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

.header-auth {
    flex: 1;
    display: flex;
    justify-content: flex-end;
    gap: 20px;
    align-items: center;
}

.btn-login {
    text-decoration: none;
    color: var(--text);
    font-size: 0.9rem;
}

.btn-signup {
    text-decoration: none;
    background: var(--secondary);
    color: var(--white) !important;
    padding: 10px 24px;
    border-radius: 25px;
    font-size: 0.85rem;
    transition: var(--transition);
}

.btn-signup:hover {
    background: var(--primary);
    transform: translateY(-1px);
}

/* Mobile Toggle */
.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    z-index: 1001;
}

.menu-toggle span {
    display: block;
    width: 25px;
    height: 2px;
    background: var(--secondary);
    transition: var(--transition);
}

/* --- 3. Questionnaire & App UI --- */
.quiz-page-wrapper {
    min-height: 85vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.quiz-container {
    background: var(--white);
    width: 100%;
    max-width: 600px;
    padding: 40px;
    border-radius: 30px;
    box-shadow: var(--shadow);
    text-align: center;
}

/* Logic for Hiding/Showing Steps */
.step {
    display: none;
}

.step.active {
    display: block;
}

/* Progress Bar */
.progress-container {
    background: #eee;
    height: 6px;
    border-radius: 10px;
    margin-bottom: 40px;
    overflow: hidden;
}

.progress-bar {
    background: var(--primary);
    height: 100%;
    width: 16%;
    transition: 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.step-number {
    font-weight: 800;
    color: var(--primary);
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 2px;
}

h2 {
    margin: 10px 0 25px;
    font-size: 1.8rem;
    color: var(--secondary);
}

/* Option Cards */
.option-grid {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.option-card {
    padding: 18px;
    border: 2px solid #f0f0f0;
    border-radius: 15px;
    cursor: pointer;
    transition: var(--transition);
    font-weight: 500;
    text-align: left;
}

.option-card:hover {
    border-color: var(--primary);
    background: #fffcfb;
}

.option-card.selected {
    border-color: var(--primary);
    background: var(--primary);
    color: var(--white);
}

/* Image Upload UI */
.upload-box {
    border: 2px dashed #ddd;
    padding: 30px;
    border-radius: 20px;
    margin: 20px 0;
    background: #fafafa;
}

.btn-finish {
    width: 100%;
    padding: 16px;
    background: var(--secondary);
    color: var(--white);
    border: none;
    border-radius: 12px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    transition: var(--transition);
}

/* Results Grid */
.routine-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin: 30px 0;
}

.product-card {
    background: #fdfbf9;
    padding: 20px;
    border-radius: 15px;
    border-left: 4px solid var(--primary);
    text-align: left;
}

/* --- 4. Responsive Breakpoints --- */

@media (max-width: 992px) {
    .menu-toggle {
        display: flex;
    }

    .nav-wrapper {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: var(--white);
        flex-direction: column;
        padding: 40px 20px;
        gap: 30px;
        margin-left: 0;
        border-top: 1px solid #eee;
        box-shadow: 0 15px 20px rgba(0, 0, 0, 0.05);
        display: none;
    }

    .nav-wrapper.is-active {
        display: flex;
    }

    .main-nav ul {
        flex-direction: column;
        align-items: center;
        gap: 20px;
    }

    .header-auth {
        flex-direction: column;
        width: 100%;
        gap: 15px;
    }

    .btn-signup {
        width: 100%;
        text-align: center;
    }

    .menu-toggle.is-active span:nth-child(1) {
        transform: translateY(7px) rotate(45deg);
    }

    .menu-toggle.is-active span:nth-child(2) {
        opacity: 0;
    }

    .menu-toggle.is-active span:nth-child(3) {
        transform: translateY(-7px) rotate(-45deg);
    }
}

@media (max-width: 500px) {
    .quiz-container {
        padding: 30px 20px;
        border-radius: 20px;
    }

    h2 {
        font-size: 1.4rem;
    }

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

    .logo a {
        font-size: 1.1rem;
    }
}

/* --- Button Uniformity --- */

/* This targets the Next, Finish, and Reset buttons */
.btn-next,
.btn-finish,
.btn-outline {
    background: var(--secondary);
    /* The Deep Navy from your variables */
    color: var(--white) !important;
    border: none;
    padding: 12px 35px;
    border-radius: 30px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.9rem;
    transition: var(--transition);
    text-decoration: none;
    display: inline-block;
}

.btn-next:hover,
.btn-finish:hover {
    background: var(--primary);
    /* Turns Earthy Rose on hover */
    transform: translateY(-1px);
}

/* Ensure the 'Choose Photo' label looks like a button */
label[for="skinPhoto"] {
    margin-bottom: 10px;
}

/* Disabled state for the 'Analyze' button */
button:disabled {
    background: #e0e0e0 !important;
    color: #aaa !important;
    cursor: not-allowed;
    transform: none !important;
}

/* --- Clean up the Reset button specifically --- */
.btn-outline {
    margin-top: 25px;
    width: auto;
    /* Keeps it from stretching too wide on desktop */
}

/* --- Home Page Specific Styles --- */

.home-wrapper {
    overflow-x: hidden;
    background: linear-gradient(135deg, #fdfcfb 0%, #e2d1c3 100%);
    /* Soft pastel transition */
}

.hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 100px 10%;
    min-height: 80vh;
    gap: 50px;
}

.hero-content {
    flex: 1;
    max-width: 600px;
}

.badge {
    background: #fff;
    padding: 6px 15px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--primary);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.03);
}

.hero h1 {
    font-size: 3.5rem;
    line-height: 1.1;
    margin: 20px 0;
    color: var(--secondary);
}

.hero h1 span {
    color: var(--primary);
    font-style: italic;
}

.hero p {
    font-size: 1.1rem;
    color: #666;
    margin-bottom: 40px;
}

/* Buttons */
.hero-btns {
    display: flex;
    gap: 20px;
}

.btn-main {
    background: var(--secondary);
    color: white;
    padding: 15px 35px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
}

.btn-main:hover {
    background: var(--primary);
    transform: translateY(-3px);
}

.btn-secondary {
    border: 2px solid var(--secondary);
    color: var(--secondary);
    padding: 13px 35px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
}

/* Hero Visual & Glassmorphism */
.hero-visual {
    flex: 1;
    display: flex;
    justify-content: center;
    position: relative;
}

.glass-card {
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.5);
    padding: 40px;
    border-radius: 40px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.05);
    width: 300px;
    animation: float 6s ease-in-out infinite;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-20px);
    }
}

.card-item {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
    font-weight: 500;
}

.card-item span {
    width: 12px;
    height: 12px;
    background: var(--primary);
    border-radius: 50%;
}

/* Stats Section */
.stats-bar {
    display: flex;
    justify-content: space-around;
    padding: 60px 10%;
    background: #fff;
}

.stat h3 {
    font-size: 2.5rem;
    color: var(--secondary);
    margin-bottom: 5px;
}

.stat p {
    color: #999;
    font-size: 0.9rem;
}

/* --- Responsive Home Page --- */
@media (max-width: 992px) {
    .hero {
        flex-direction: column;
        text-align: center;
        padding: 60px 5%;
    }

    .hero h1 {
        font-size: 2.5rem;
    }

    .hero-btns {
        justify-content: center;
    }

    .hero-visual {
        order: -1;
    }

    /* Image on top on mobile */

    .stats-bar {
        flex-direction: column;
        gap: 40px;
        text-align: center;
    }
}

/* --- Aesthetic Minimal Footer --- */

.site-footer {
    background: #fff;
    padding: 80px 10% 40px;
    border-top: 1px solid #f0f0f0;
    font-size: 0.9rem;
    color: var(--text);
}

.footer-container {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
}

.footer-col {
    flex: 1;
    min-width: 200px;
}

.brand-col {
    flex: 2;
    /* Brand section takes more space */
    max-width: 300px;
}

.brand-col p {
    margin-top: 15px;
    color: var(--text-light);
    line-height: 1.7;
}

.footer-col h4 {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 25px;
    color: var(--secondary);
}

.footer-col ul {
    list-style: none;
    padding: 0;
}

.footer-col ul li {
    margin-bottom: 12px;
}

.footer-col ul li a {
    text-decoration: none;
    color: var(--text-light);
    transition: var(--transition);
}

.footer-col ul li a:hover {
    color: var(--primary);
}

/* Newsletter Input */
.footer-form {
    display: flex;
    margin-top: 20px;
    border-bottom: 1px solid #ddd;
    padding-bottom: 5px;
}

.footer-form input {
    border: none;
    background: transparent;
    padding: 10px 0;
    flex: 1;
    outline: none;
    font-family: inherit;
    font-size: 0.85rem;
}

.footer-form button {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.2rem;
    color: var(--primary);
}

.footer-bottom {
    margin-top: 60px;
    padding-top: 30px;
    border-top: 1px solid #f7f7f7;
    text-align: center;
    color: #bbb;
    font-size: 0.75rem;
}

/* --- Responsive Footer --- */
@media (max-width: 768px) {
    .site-footer {
        padding: 60px 5% 30px;
        text-align: center;
    }

    .footer-container {
        flex-direction: column;
        align-items: center;
    }

    .brand-col {
        max-width: 100%;
        margin-bottom: 20px;
    }

    .footer-form {
        justify-content: center;
        max-width: 250px;
        margin: 20px auto;
    }
}

/* --- 3-Angle Photo Grid --- */
.photo-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    margin-top: 20px;
}

.photo-slot {
    position: relative;
    background: #fdfbf9;
    border: 2px dashed #ddd;
    border-radius: 15px;
    padding: 20px 10px;
    transition: var(--transition);
    height: 140px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.photo-slot:hover {
    border-color: var(--primary);
    background: #fff;
}

.photo-slot input[type="file"] {
    display: none;
    /* Hide original input */
}

.slot-label {
    cursor: pointer;
    text-align: center;
    width: 100%;
}

.slot-label .icon {
    font-size: 1.8rem;
    display: block;
    margin-bottom: 5px;
}

.slot-label .label-text {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--secondary);
}

.mini-preview {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: none;
    border-radius: 13px;
    overflow: hidden;
}

.mini-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Ensure mobile stacking if screen is very small */
@media (max-width: 480px) {
    .photo-grid {
        grid-template-columns: 1fr;
        /* Stacks vertically on tiny phones */
    }

    .photo-slot {
        height: 100px;
    }
}

/* --- Engaging Home Elements --- */

/* Hero Enhancements */
.badge-wrapper {
    margin-bottom: 15px;
}

.hero-trust {
    margin-top: 25px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.85rem;
    color: #888;
}

.hero-visual {
    position: relative;
    height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-circle {
    position: absolute;
    width: 350px;
    height: 350px;
    background: radial-gradient(circle, rgba(173, 141, 130, 0.2) 0%, transparent 70%);
    border-radius: 50%;
    z-index: -1;
}

.ui-card {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    padding: 15px 25px;
    border-radius: 15px;
    box-shadow: var(--shadow);
    position: absolute;
    font-size: 0.9rem;
}

.analysis {
    top: 20%;
    left: 10%;
    border-left: 4px solid var(--primary);
    animation: float 4s infinite ease-in-out;
}

.result {
    bottom: 20%;
    right: 10%;
    border-left: 4px solid var(--secondary);
    animation: float 4s infinite ease-in-out 1s;
}

.scan-bar {
    width: 100%;
    height: 2px;
    background: var(--primary);
    position: relative;
    overflow: hidden;
    margin-bottom: 8px;
}

.scan-bar::after {
    content: '';
    position: absolute;
    left: -100%;
    width: 100%;
    height: 100%;
    background: white;
    animation: scanLine 2s infinite linear;
}

@keyframes scanLine {
    100% {
        left: 100%;
    }
}

/* Marquee Effect */
.marquee {
    background: var(--white);
    padding: 20px 0;
    border-top: 1px solid #f0f0f0;
    border-bottom: 1px solid #f0f0f0;
    overflow: hidden;
    white-space: nowrap;
}

.marquee-content {
    display: inline-block;
    animation: scroll 20s linear infinite;
    color: #ccc;
    font-size: 0.9rem;
}

.marquee-content strong {
    color: #555;
    margin: 0 40px;
    letter-spacing: 2px;
}

@keyframes scroll {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

/* Steps Cards */
.how-it-works {
    padding: 100px 10%;
    background: #fff;
    text-align: center;
}

.section-title h2 {
    font-size: 2.5rem;
    margin-bottom: 15px;
}

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

.step-card {
    padding: 40px;
    background: var(--bg-light);
    border-radius: 25px;
    transition: var(--transition);
}

.step-card:hover {
    transform: translateY(-10px);
    background: #fff;
    box-shadow: var(--shadow);
}

.step-icon {
    width: 50px;
    height: 50px;
    background: var(--secondary);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-weight: 800;
}

/* Comparison Section */
.comparison {
    padding: 80px 10%;
    display: flex;
    justify-content: center;
}

.comp-box {
    display: flex;
    background: #fff;
    border-radius: 30px;
    overflow: hidden;
    box-shadow: var(--shadow);
    max-width: 800px;
    width: 100%;
}

.comp-item {
    flex: 1;
    padding: 50px 40px;
    position: relative;
}

.traditional {
    background: #fafafa;
    color: #999;
}

.clearify {
    background: var(--secondary);
    color: #fff;
}

.clearify ul {
    list-style: none;
    padding: 0;
}

.clearify li::before {
    content: '✓ ';
    color: var(--primary);
}

.best-value {
    position: absolute;
    top: 15px;
    right: 15px;
    background: var(--primary);
    padding: 4px 12px;
    border-radius: 10px;
    font-size: 0.7rem;
    font-weight: 700;
}

/* Final CTA */
.final-cta {
    padding: 100px 10%;
    text-align: center;
    background: linear-gradient(rgba(173, 141, 130, 0.1), rgba(255, 255, 255, 0));
}

.final-cta h2 {
    font-size: 2.5rem;
    margin-bottom: 30px;
}

/* Responsive Styling */
@media (max-width: 768px) {
    .steps-grid {
        grid-template-columns: 1fr;
    }

    .comp-box {
        flex-direction: column;
    }

    .hero h1 {
        font-size: 2.2rem;
    }
}

/* --- Optimized Hero Section --- */
.hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 120px 10% 80px;
    /* Extra top padding for breathing room */
    min-height: 70vh;
    gap: 60px;
    background: radial-gradient(circle at top right, rgba(173, 141, 130, 0.08), transparent);
}

.hero-content {
    flex: 1.2;
    max-width: 650px;
    text-align: left;
}

.hero h1 {
    font-size: 3.8rem;
    line-height: 1.1;
    margin-bottom: 25px;
    color: var(--secondary);
    font-weight: 800;
}

.hero h1 span {
    color: var(--primary);
    display: block;
    /* Moves 'routine' to its own line for impact */
    font-style: italic;
}

.hero p {
    font-size: 1.15rem;
    color: var(--text-light);
    margin-bottom: 40px;
    line-height: 1.7;
}

/* --- Simplified Visual Component --- */
.hero-visual {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.info-card {
    background: var(--white);
    padding: 24px;
    border-radius: 20px;
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    gap: 20px;
    border: 1px solid rgba(0, 0, 0, 0.03);
    transition: var(--transition);
}

.info-card:hover {
    transform: translateX(-10px);
}

.info-card .icon-dot {
    width: 12px;
    height: 12px;
    background: var(--primary);
    border-radius: 50%;
}

.info-card .card-text {
    font-weight: 600;
    font-size: 1rem;
    color: var(--secondary);
}

/* --- Responsive Neatness --- */
@media (max-width: 992px) {
    .hero {
        flex-direction: column;
        text-align: center;
        padding: 60px 5%;
        gap: 40px;
    }

    .hero-content {
        max-width: 100%;
    }

    .hero h1 {
        font-size: 2.8rem;
    }

    .hero-visual {
        width: 100%;
        align-items: center;
    }

    .info-card {
        width: 100%;
        max-width: 400px;
    }
}

:root {
    --primary: #ad8d82;
    --secondary: #2c3e50;
    --bg-light: #faf9f6;
    --white: #ffffff;
    --text: #333333;
    --text-light: #5f6368;
    /* Slightly softer than pure black */
    --shadow: 0 15px 35px rgba(44, 62, 80, 0.06);
    /* Softer, deep-navy tinted shadow */
    --transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

/* --- Hide Floating UI on Mobile --- */
@media (max-width: 768px) {

    .hero-visual,
    .ui-card,
    .analysis,
    .result,
    .hero-circle {
        display: none !important;
    }

    .hero {
        padding: 60px 5%;
        text-align: center;
        min-height: auto;
    }

    .hero-content {
        max-width: 100%;
        margin: 0 auto;
    }
}

.page-content .um {
    max-width: 450px;
    margin: 40px auto;
    background: #fff;
    padding: 30px;
    border-radius: 20px;
    box-shadow: var(--shadow);
}

/* --- Center Headings on Login/Register Pages --- */
.container h2 {
    text-align: center;
    font-size: 2.2rem;
    margin-bottom: 40px;
    color: var(--secondary);
    /* Deep Navy */
}

/* Optional: Center the paragraph text if you have any */
.page-content {
    text-align: center;
}

/* Keep the Ultimate Member form centered and aligned */
.um {
    text-align: left;
    /* Keeps the form labels aligned properly inside the centered container */
    margin: 0 auto;
}

.save-results-box {
    transition: transform 0.3s ease;
}

.save-results-box:hover {
    transform: scale(1.02);
}

.save-results-box .btn-signup:hover {
    background: var(--primary) !important;
}

/* Style the Ultimate Member Account/Edit section */
.um-account-main {
    background: #fff;
    padding: 30px;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    margin-top: 40px;
}

.um-account-nav {
    border-bottom: 1px solid #eee;
    margin-bottom: 20px;
}

.um-account-side li a.current,
.um-account-name a:hover {
    color: #ad8d82 !important;
    /* Matches your scanner line color */
}