/* KnzFairyGlow - Professional Skincare Brand Styling */

/* Import Google Fonts for elegant typography */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;600;700&family=Inter:wght@300;400;500;600;700&display=swap');

/* CSS Custom Properties for Brand Colors */
:root {
    /* Core palette extracted from brand imagery (warm skin tones, soft neutrals, muted luxe accents) */
    --brand-primary: #C9A676;        /* Champagne gold highlight (from 001/002 jewelry tones) */
    --brand-secondary: #856447;      /* Warm earthy bronze (deep shadows in 004/006) */
    --brand-accent: #F5F2EC;         /* Soft off-white background (light areas in 005/008) */
    --brand-dark: #262321;           /* Rich near-black brown (hair/liner tones) */
    --brand-light: #FFFFFF;          /* Pure white */
    --brand-rose: #D8B299;           /* Muted rosy beige (cheek/lip undertones) */
    --brand-grey: #EFE9E3;           /* Pale neutral filler */
    --brand-blush: #E7C7B4;          /* Light blush accent (skin highlight) */
    --brand-shadow: rgba(38,35,33,0.25); /* Unified shadow tone */
    --brand-gradient: linear-gradient(135deg, var(--brand-accent) 0%, var(--brand-blush) 40%, var(--brand-accent) 100%);
    
    /* Logo theming (inherits from brand by default) */
    --logo-primary: var(--brand-primary);
    --logo-secondary: var(--brand-secondary);
    --logo-glow-1: rgba(201, 166, 118, 0.35); /* derived from brand-primary */
    --logo-glow-2: rgba(216, 178, 153, 0.25); /* derived from brand-rose */
    
    /* Typography */
    --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-display: 'Playfair Display', Georgia, serif;
    
    /* Shadows */
    --shadow-subtle: 0 2px 12px rgba(200, 168, 130, 0.08);
    --shadow-medium: 0 8px 25px rgba(200, 168, 130, 0.12);
    --shadow-strong: 0 15px 35px rgba(200, 168, 130, 0.18);
    
    /* Border Radius */
    --radius-small: 8px;
    --radius-medium: 12px;
    --radius-large: 20px;
}

/* Reset and Base Styles */
* {
    box-sizing: border-box;
}

body {
    font-family: var(--font-primary);
    font-weight: 400;
    line-height: 1.6;
    color: var(--brand-dark);
    background-color: var(--brand-light);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Typography Scale */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-display);
    font-weight: 600;
    line-height: 1.3;
    margin: 0 0 1rem 0;
    color: var(--brand-dark);
}

h1 { font-size: clamp(2rem, 5vw, 3.5rem); }
h2 { font-size: clamp(1.5rem, 4vw, 2.5rem); }
h3 { font-size: clamp(1.25rem, 3vw, 2rem); }

p {
    margin: 0 0 1rem 0;
    font-size: 1rem;
    color: var(--brand-dark);
    opacity: 0.9;
}

/* Navigation */
.navbar {
    background: var(--brand-light) !important;
    -webkit-backdrop-filter: blur(20px);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(200, 168, 130, 0.1);
    padding: 1rem 0;
    transition: all 0.3s ease;
}

.navbar-brand {
    font-family: var(--font-display);
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--brand-primary) !important;
    text-decoration: none;
    letter-spacing: -0.02em;
}

.navbar-brand:hover {
    color: var(--brand-secondary) !important;
}

/* Mobile navbar toggler visibility & theming */
.navbar .navbar-toggler {
    border: 2px solid var(--brand-primary) !important;
    border-radius: var(--radius-small);
    padding: 0.35rem 0.55rem;
    background: var(--brand-accent);
    box-shadow: 0 2px 6px rgba(201,166,118,0.25);
    transition: all 0.3s ease;
}
.navbar .navbar-toggler:focus,
.navbar .navbar-toggler:hover {
    outline: none;
    background: var(--brand-primary);
    box-shadow: 0 4px 12px rgba(201,166,118,0.35);
}
.navbar .navbar-toggler:focus .navbar-toggler-icon,
.navbar .navbar-toggler:hover .navbar-toggler-icon {
    filter: brightness(1.15);
}
/* Custom colored hamburger icon (brand primary strokes) */
.navbar-light .navbar-toggler-icon, .navbar .navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 30 30' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath stroke='%23C9A676' stroke-linecap='round' stroke-miterlimit='10' stroke-width='3' d='M4 7h22M4 15h22M4 23h22'/%3E%3C/svg%3E") !important;
}

/* Fancy Logo Shared Styles */
.fancy-logo { color: var(--logo-primary); isolation: isolate; }

.fancy-logo .logo-icon-wrapper {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: radial-gradient(circle at 35% 35%, var(--logo-primary) 0%, var(--logo-secondary) 55%, var(--brand-dark) 100%);
    box-shadow: 0 4px 16px rgba(201,166,118,0.35), inset 0 0 12px rgba(255,255,255,0.15);
    overflow: visible;
}

.fancy-logo .logo-icon-wrapper i {
    color: var(--brand-light) !important;
    font-size: 1.25rem;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.25));
}

.fancy-logo .logo-glow {
    position: absolute;
    top: -6px; left: -6px; right: -6px; bottom: -6px;
    border-radius: 50%;
    background: radial-gradient(circle, var(--logo-glow-1) 0%, var(--logo-glow-2) 45%, transparent 70%);
    opacity: 0.7;
    pointer-events: none;
    animation: logoPulse 5s ease-in-out infinite;
    mix-blend-mode: screen;
}

.fancy-logo .logo-text {
    background: linear-gradient(90deg, var(--logo-primary) 0%, var(--logo-secondary) 50%, var(--logo-primary) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    position: relative;
    display: inline-block;
    padding: 2px 4px;
}

.fancy-logo .logo-text::after {
    content: '';
    position: absolute;
    left: 0; bottom: -4px;
    width: 100%; height: 3px;
    background: linear-gradient(90deg, rgba(201,166,118,0.65), rgba(216,178,153,0.4), rgba(201,166,118,0.65));
    border-radius: 3px;
    filter: blur(0.5px);
    opacity: 0.85;
}

.fancy-logo:hover .logo-icon-wrapper {
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 6px 22px rgba(201,166,118,0.45), inset 0 0 12px rgba(255,255,255,0.18);
    transition: all 0.5s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.fancy-logo:hover .logo-text::after {
    animation: underlineSweep 1.8s linear infinite;
}

@keyframes logoPulse {
    0%, 100% { opacity: 0.7; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.08); }
}

@keyframes underlineSweep {
    0% { filter: brightness(1); opacity: 0.85; }
    50% { filter: brightness(1.3); opacity: 1; }
    100% { filter: brightness(1); opacity: 0.85; }
}

/* Adaptive variants for navbar contexts */
.navbar.navbar-light .fancy-logo { color: var(--logo-primary); }
.navbar.navbar-dark .fancy-logo { color: var(--brand-accent); }

.nav-link {
    font-weight: 500;
    color: var(--brand-dark) !important;
    padding: 0.5rem 1rem !important;
    border-radius: var(--radius-small);
    transition: all 0.3s ease;
    position: relative;
}

.nav-link:hover {
    color: var(--brand-primary) !important;
    background-color: var(--brand-accent);
}

/* Hero Section */
.hero-section {
    min-height: 70vh;
    background: var(--brand-gradient);
    position: relative;
    overflow: hidden;
}

/* Replace static grain with subtle radial vignette for more refined look */
.hero-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 30% 30%, rgba(201,166,118,0.25), transparent 70%),
                radial-gradient(circle at 70% 60%, rgba(216,178,153,0.2), transparent 75%);
    mix-blend-mode: multiply;
    pointer-events: none;
}

.hero-section .display-4 {
    font-family: var(--font-display);
    font-weight: 700;
    color: var(--brand-dark);
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

.hero-section .lead {
    font-size: 1.25rem;
    font-weight: 400;
    color: var(--brand-dark);
    opacity: 0.8;
    margin-bottom: 2rem;
    max-width: 500px;
}

/* Cards and Product Styling */
.card {
    border: none;
    border-radius: var(--radius-medium);
    box-shadow: var(--shadow-subtle);
    transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
    overflow: hidden;
    background: var(--brand-light);
}

.card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-strong);
}

.card-img-top {
    border-radius: 0;
    transition: transform 0.4s ease;
}

.card:hover .card-img-top {
    transform: scale(1.05);
}

.card-body {
    padding: 1.5rem;
}

.card-title {
    font-family: var(--font-display);
    font-weight: 600;
    color: var(--brand-dark);
    margin-bottom: 0.75rem;
    font-size: 1.25rem;
}

.card-text {
    color: var(--brand-dark);
    opacity: 0.8;
    font-size: 0.95rem;
    line-height: 1.5;
}

.card-footer {
    background: transparent !important;
    border-top: 1px solid rgba(200, 168, 130, 0.1);
    padding: 1.25rem 1.5rem;
}

/* Buttons */
.btn {
    font-weight: 600;
    border-radius: var(--radius-small);
    padding: 0.75rem 2rem;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    border: none;
    letter-spacing: 0.02em;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: linear-gradient(135deg, var(--brand-primary) 0%, var(--brand-secondary) 100%);
    color: var(--brand-light);
    box-shadow: var(--shadow-subtle);
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--brand-secondary) 0%, var(--brand-primary) 100%);
    transform: translateY(-2px);
    box-shadow: var(--shadow-medium);
    color: var(--brand-light);
}

.btn-light {
    background: var(--brand-light);
    color: var(--brand-dark);
    border: 2px solid var(--brand-primary);
}

.btn-light:hover {
    background: var(--brand-primary);
    color: var(--brand-light);
    border-color: var(--brand-primary);
}

.btn-lg {
    padding: 1rem 2.5rem;
    font-size: 1.1rem;
}

/* Price Display */
.text-primary {
    color: var(--brand-primary) !important;
}

.fs-4 {
    font-weight: 700;
}

/* Section Styling */
section {
    padding: 4rem 0;
}

.bg-light {
    background: var(--brand-grey) !important;
}

/* Contact Section Icons */
.fas {
    color: var(--brand-primary);
    margin-right: 0.5rem;
}

/* Footer */
footer {
    background: var(--brand-dark);
    color: var(--brand-light);
}

footer a {
    text-decoration: none;
    color: var(--brand-primary);
    transition: all 0.3s ease;
}

footer a:hover {
    color: var(--brand-rose);
    text-decoration: none;
}

/* Ensure footer text contrasts correctly on dark background */
footer h1,
footer h2,
footer h3,
footer h4,
footer h5,
footer h6 {
    color: var(--brand-light) !important;
}

footer p,
footer li,
footer span,
footer small,
footer i {
    color: rgba(255, 255, 255, 0.9) !important;
}

/* Social icons within footer: keep bright for clarity */
footer .fab,
footer .fas {
    color: var(--brand-light) !important;
}

/* Utility: if any .text-muted appears in footer, lift contrast */
footer .text-muted {
    color: rgba(255, 255, 255, 0.7) !important;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero-section {
        min-height: 60vh;
        text-align: center;
    }
    
    .hero-section .col-md-6:last-child {
        margin-top: 2rem;
    }
    
    .card-body {
        padding: 1.25rem;
    }
    
    .btn {
        padding: 0.65rem 1.5rem;
        font-size: 0.9rem;
    }
    
    section {
        padding: 3rem 0;
    }
}

@media (max-width: 576px) {
    .hero-section {
        min-height: 50vh;
    }
    
    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .btn-lg {
        padding: 0.875rem 2rem;
        font-size: 1rem;
    }
}

/* Hero Section Enhancements */
.min-vh-75 {
    min-height: 75vh;
}

.trust-indicators {
    padding: 1rem 0;
    border-top: 1px solid rgba(200, 168, 130, 0.2);
}

/* Beauty Icon Container */
.beauty-icon-container {
    position: relative;
    height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.floating-icon {
    position: absolute;
    animation: float 3s ease-in-out infinite;
    animation-delay: var(--delay);
}

.floating-icon:nth-child(1) {
    top: 20%;
    left: 20%;
}

.floating-icon:nth-child(2) {
    top: 60%;
    right: 20%;
}

.floating-icon:nth-child(3) {
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.central-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 240px;
    height: 240px;
    background: radial-gradient(circle, rgba(201,166,118,0.35) 0%, rgba(216,178,153,0.25) 35%, transparent 70%);
    border-radius: 50%;
    animation: pulse-glow 6s ease-in-out infinite;
    filter: blur(2px);
}

/* Feature Icons */
.feature-icon {
    padding: 1rem;
    border-radius: var(--radius-medium);
    background: linear-gradient(145deg, rgba(201,166,118,0.12), rgba(216,178,153,0.18));
    display: inline-block;
    margin-bottom: 1rem;
    transition: all 0.35s ease;
    box-shadow: 0 4px 14px var(--brand-shadow);
}

.feature-icon:hover {
    transform: translateY(-5px);
    background: rgba(200, 168, 130, 0.2);
}

/* Product Cards Enhanced */
.product-card:hover .card-img-top {
    transform: scale(1.08);
}

.product-meta {
    border-top: 1px solid rgba(200, 168, 130, 0.1);
    padding-top: 1rem;
}

/* About Section Showcase */
.brand-showcase {
    padding: 2rem;
}

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

.showcase-item {
    padding: 2rem 1rem;
    background: linear-gradient(160deg, var(--brand-accent) 0%, #faf7f3 60%, var(--brand-accent) 100%);
    border-radius: var(--radius-medium);
    transition: all 0.35s ease;
    border: 1px solid rgba(201,166,118,0.18);
}

.showcase-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-medium);
}

.showcase-item h6 {
    color: var(--brand-dark);
    font-weight: 600;
    margin: 0;
}

/* Hero Decorations */
.hero-decoration {
    position: absolute;
    top: 0;
    right: -10%;
    width: 320px;
    height: 320px;
    background: radial-gradient(circle at center, rgba(216,178,153,0.25) 0%, transparent 70%);
    border-radius: 50%;
    z-index: -1;
    filter: blur(3px);
}

/* Loading and Animation States */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-20px);
    }
}

@keyframes pulse-glow {
    0%, 100% {
        opacity: 0.3;
        transform: translate(-50%, -50%) scale(1);
    }
    50% {
        opacity: 0.6;
        transform: translate(-50%, -50%) scale(1.1);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease-out;
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Focus States */
.btn:focus,
.nav-link:focus {
    outline: 2px solid var(--brand-primary);
    outline-offset: 2px;
}

/* High Contrast Support */
@media (prefers-contrast: high) {
    :root {
        --brand-primary: #8b6f57;
        --brand-secondary: #2c2c2c;
        --shadow-subtle: 0 2px 8px rgba(0, 0, 0, 0.3);
    }
}
