/* ============================================
   Sailor Moon Brooklyn — Custom Styles
   ============================================ */

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

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    overflow-x: hidden;
}

::selection {
    background-color: rgba(201, 168, 76, 0.3);
    color: #f0f3f9;
}

/* --- Scrollbar --- */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #091730;
}
::-webkit-scrollbar-thumb {
    background: #1a3565;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #c9a84c;
}

/* --- Navigation --- */
.nav-header {
    background: transparent;
    transition: background 0.5s ease, box-shadow 0.5s ease;
}

.nav-header.scrolled {
    background: rgba(5, 14, 26, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(201, 168, 76, 0.1);
}

.nav-link {
    position: relative;
}

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

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

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

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

.mobile-nav-link {
    position: relative;
    padding-left: 0;
}

/* --- Hero --- */
.hero {
    position: relative;
}

.hero-bg {
    will-change: transform;
}

.hero-img {
    will-change: transform;
}

.hero-content {
    will-change: opacity, transform;
}

.hero-badge {
    will-change: opacity, transform;
}

.hero-title {
    will-change: opacity, transform;
}

.hero-subtitle {
    will-change: opacity, transform;
}

.hero-cta {
    will-change: opacity, transform;
}

/* --- Scroll Indicator --- */
.scroll-line {
    animation: scrollPulse 2s ease-in-out infinite;
    transform-origin: top;
}

@keyframes scrollPulse {
    0%, 100% {
        opacity: 0.3;
        transform: scaleY(0.6);
    }
    50% {
        opacity: 1;
        transform: scaleY(1);
    }
}

/* --- Buttons --- */
.cta-primary {
    box-shadow: 0 4px 20px rgba(201, 168, 76, 0.3);
    transition: all 0.3s ease;
}

.cta-primary:hover {
    box-shadow: 0 8px 30px rgba(201, 168, 76, 0.4);
    transform: translateY(-2px);
}

.cta-secondary {
    transition: all 0.3s ease;
}

.cta-secondary:hover {
    box-shadow: 0 4px 20px rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

/* --- Room Cards --- */
.room-card {
    transition: transform 0.4s ease;
}

.room-card:hover {
    transform: translateY(-4px);
}

/* --- Amenities --- */
.amenity-item {
    transition: transform 0.3s ease;
}

.amenity-item:hover {
    transform: translateX(4px);
}

.amenity-icon {
    transition: all 0.3s ease;
}

.amenity-item:hover .amenity-icon {
    background: rgba(201, 168, 76, 0.1);
    border-color: rgba(201, 168, 76, 0.6);
}

/* --- Gallery --- */
.gallery img {
    transition: transform 0.7s ease;
}

.gallery img:hover {
    transform: scale(1.05);
}

/* --- Contact Form --- */
.contact-form input,
.contact-form textarea {
    transition: border-color 0.3s ease;
}

.contact-form input:focus,
.contact-form textarea:focus {
    border-color: #c9a84c;
    box-shadow: 0 0 0 1px rgba(201, 168, 76, 0.2);
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
    color: #4164af;
}

/* --- Back to Top --- */
.back-to-top {
    transition: all 0.3s ease;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(201, 168, 76, 0.4);
}

/* --- Reveal Animations --- */
/* Default state: visible (progressive enhancement) */
.reveal {
    opacity: 1;
    transform: none;
}

/* When JS adds the animated class, apply transitions */
.reveal.animated {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.animated.visible {
    opacity: 1;
    transform: translateY(0);
}

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

/* --- Responsive --- */
@media (max-width: 767px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-title br {
        display: none;
    }
    
    .intro,
    .rooms,
    .amenities,
    .location,
    .gallery,
    .quote-section,
    .contact {
        padding-top: 4rem;
        padding-bottom: 4rem;
    }
}

@media (min-width: 768px) and (max-width: 1023px) {
    .hero-title {
        font-size: 3.5rem;
    }
}

/* --- Print --- */
@media print {
    .nav-header,
    .back-to-top,
    .hero-scroll {
        display: none;
    }
    
    body {
        background: white;
        color: #1a2744;
    }
}
