/* ========================================
   Epiphany's Salon - Custom Styles
   Charcoal & Coral Palette
   ======================================== */

/* Base & Reset */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    overflow-x: hidden;
}

/* Selection Color */
::selection {
    background-color: rgba(255, 107, 60, 0.3);
    color: #f6f6f7;
}

/* ========================================
   Navigation
   ======================================== */
.nav-fixed {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    background: transparent;
}

.nav-fixed.scrolled {
    background: rgba(9, 9, 11, 0.95);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(161, 161, 170, 0.1);
}

.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background: #ff6b3c;
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

.nav-link:hover {
    color: #ff6b3c !important;
}

/* Mobile Menu */
.mobile-menu {
    animation: slideDown 0.3s ease forwards;
}

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

.mobile-link {
    position: relative;
    display: block;
    padding: 8px 0;
}

/* ========================================
   Hero Section
   ======================================== */
.hero {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
}

.hero-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.hero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-overlay {
    background: linear-gradient(
        to bottom,
        rgba(9, 9, 11, 0.6) 0%,
        rgba(9, 9, 11, 0.4) 50%,
        rgba(9, 9, 11, 0.8) 100%
    );
}

.hero-content {
    padding: 0 1.5rem;
}

.hero-subtitle {
    letter-spacing: 0.3em;
}

.hero-title {
    line-height: 1.1;
}

.hero-desc {
    line-height: 1.8;
}

/* Hero Scroll Indicator */
.hero-scroll {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.scroll-line {
    animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
    0%, 100% {
        opacity: 0.3;
        transform: scaleY(0.5);
        transform-origin: top;
    }
    50% {
        opacity: 1;
        transform: scaleY(1);
    }
}

/* ========================================
   Section Styles
   ======================================== */
.section-tag {
    letter-spacing: 0.3em;
}

.section-title {
    line-height: 1.2;
}

.section-line {
    margin-left: auto;
    margin-right: auto;
}

.section-desc {
    line-height: 1.8;
}

/* ========================================
   Service Cards
   ======================================== */
.service-card {
    perspective: 1000px;
}

.service-card-inner {
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1), border-color 0.5s ease;
}

.service-card:hover .service-card-inner {
    transform: translateY(-8px);
}

.service-icon {
    transition: transform 0.3s ease;
}

.service-card:hover .service-icon {
    transform: scale(1.1);
}

.service-link {
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.service-card:hover .service-link {
    opacity: 1;
}

/* ========================================
   About Section
   ======================================== */
.about-image-wrapper {
    position: relative;
}

.about-image-main img {
    width: 100%;
    height: auto;
    display: block;
}

.about-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.stat-number {
    font-weight: 300;
}

.stat-label {
    letter-spacing: 0.15em;
}

/* ========================================
   Gallery
   ======================================== */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.75rem;
}

.gallery-item-inner {
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.gallery-img {
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-item-inner::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(9, 9, 11, 0.6) 0%, transparent 60%);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.gallery-item:hover .gallery-img {
    transform: scale(1.08);
}

.gallery-item:hover .gallery-item-inner::after {
    opacity: 1;
}

/* ========================================
   Testimonials
   ======================================== */
.testimonial-card {
    perspective: 1000px;
}

.testimonial-card-inner {
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1), border-color 0.5s ease;
}

.testimonial-card:hover .testimonial-card-inner {
    transform: translateY(-4px);
    border-color: rgba(255, 107, 60, 0.3);
}

.testimonial-quote {
    opacity: 0.6;
}

.testimonial-text {
    line-height: 1.8;
}

.testimonial-author {
    padding-top: 1.5rem;
    border-top: 1px solid rgba(161, 161, 170, 0.15);
}

/* ========================================
   CTA Section
   ======================================== */
.cta {
    position: relative;
}

.cta-bg {
    position: absolute;
    inset: 0;
}

.cta-overlay {
    background: linear-gradient(
        to right,
        rgba(9, 9, 11, 0.85) 0%,
        rgba(9, 9, 11, 0.6) 50%,
        rgba(9, 9, 11, 0.85) 100%
    );
}

.cta-content {
    padding: 0 1.5rem;
}

/* ========================================
   Buttons
   ======================================== */
.btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.btn-primary::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, transparent 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.btn-primary:hover::before {
    opacity: 1;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 40px rgba(255, 107, 60, 0.3);
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-secondary:hover {
    transform: translateY(-2px);
}

/* ========================================
   Contact Form
   ======================================== */
.form-label {
    display: block;
    margin-bottom: 0.5rem;
}

.form-input {
    display: block;
    width: 100%;
    font-size: 0.9375rem;
}

.form-input::placeholder {
    color: #71717a;
}

.form-input:focus {
    border-color: #ff6b3c !important;
    box-shadow: 0 0 0 3px rgba(255, 107, 60, 0.1);
}

.form-input option {
    background: #18181b;
    color: #e3e3e5;
}

.form-row {
    display: grid;
    gap: 1.5rem;
}

/* ========================================
   Social Links
   ======================================== */
.social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.social-link:hover {
    transform: translateY(-3px);
}

/* ========================================
   Footer
   ======================================== */
.footer {
    position: relative;
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 1px;
    background: linear-gradient(to right, transparent, #ff6b3c, transparent);
}

/* ========================================
   Back to Top Button
   ======================================== */
.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 48px;
    height: 48px;
    background: rgba(255, 107, 60, 0.9);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s ease;
    z-index: 999;
    backdrop-filter: blur(10px);
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    background: #f04e18;
    transform: translateY(-4px);
    box-shadow: 0 8px 30px rgba(255, 107, 60, 0.4);
}

/* ========================================
   Reveal Animations
   ======================================== */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1), transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ========================================
   Responsive
   ======================================== */
@media (max-width: 1023px) {
    .gallery-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 767px) {
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .about-stats {
        grid-template-columns: repeat(3, 1fr);
        gap: 1.5rem;
    }
    
    .stat-number {
        font-size: 2rem !important;
    }
}

@media (max-width: 639px) {
    .gallery-grid {
        grid-template-columns: 1fr;
    }
    
    .gallery-item-inner {
        aspect-ratio: 4/3;
    }
    
    .hero-title {
        font-size: 2.5rem !important;
    }
    
    .hero-title br {
        display: none;
    }
    
    .section-title {
        font-size: 2.5rem !important;
    }
    
    .cta-title {
        font-size: 2.5rem !important;
    }
    
    .cta-title br {
        display: none;
    }
}

@media (min-width: 768px) and (max-width: 1023px) {
    .gallery-item-inner {
        aspect-ratio: auto;
    }
}

/* ========================================
   Reduced Motion
   ======================================== */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    html {
        scroll-behavior: auto;
    }
    
    .reveal {
        opacity: 1;
        transform: none;
    }
    
    .back-to-top {
        transition: none;
    }
}
