/* ═══════════════════════════════════════════
   Tea N' Me — Custom Styles
   ═══════════════════════════════════════════ */

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

body {
    overflow-x: hidden;
}

/* ── Navbar ── */
#navbar {
    background: transparent;
    transition: background 0.3s ease, box-shadow 0.3s ease, backdrop-filter 0.3s ease;
}

#navbar.scrolled {
    background: rgba(253, 252, 248, 0.92);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 1px 20px rgba(20, 39, 15, 0.08);
}

.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: #3a6b2c;
    transition: width 0.2s ease;
    border-radius: 1px;
}

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

#navbar.scrolled .nav-link {
    color: #1b3314;
}

#navbar.scrolled .nav-link::after {
    background: #3a6b2c;
}

/* ── Mobile Menu ── */
.mobile-nav-link {
    position: relative;
}

/* ── Reveal Animations (progressive enhancement) ── */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(30px);
        transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
    }

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

    .reveal:nth-child(2) { transition-delay: 0.1s; }
    .reveal:nth-child(3) { transition-delay: 0.2s; }
    .reveal:nth-child(4) { transition-delay: 0.3s; }
}

/* ── Hero floating cards animation ── */
@keyframes float-slow {
    0%, 100% { transform: translateY(0px) rotate(-2deg); }
    50% { transform: translateY(-10px) rotate(-2deg); }
}

@keyframes float-medium {
    0%, 100% { transform: translateY(0px) rotate(1deg); }
    50% { transform: translateY(-8px) rotate(1deg); }
}

@keyframes float-fast {
    0%, 100% { transform: translateY(0px) rotate(-1deg); }
    50% { transform: translateY(-6px) rotate(-1deg); }
}

@keyframes float-accent {
    0%, 100% { transform: translateY(0px) rotate(2deg); }
    50% { transform: translateY(-12px) rotate(2deg); }
}

@media (prefers-reduced-motion: no-preference) {
    .hero-card-1 { animation: float-slow 6s ease-in-out infinite; }
    .hero-card-2 { animation: float-medium 5s ease-in-out infinite; }
    .hero-card-3 { animation: float-fast 4.5s ease-in-out infinite; }
    .hero-card-4 { animation: float-medium 5.5s ease-in-out infinite; }
    .hero-card-5 { animation: float-accent 4s ease-in-out infinite; }
}

/* ── Custom scrollbar ── */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #faf8f0;
}

::-webkit-scrollbar-thumb {
    background: #a8c59a;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #7aa368;
}

/* ── Selection ── */
::selection {
    background: #a8c59a;
    color: #1b3314;
}

/* ── Focus visible ── */
:focus-visible {
    outline: 2px solid #3a6b2c;
    outline-offset: 2px;
}

/* ── Canvas background ── */
#bg-canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

/* ── Smooth image loading ── */
img {
    opacity: 1;
    transition: opacity 0.3s ease;
}

img[data-src] {
    opacity: 0;
}

/* ── Map container ── */
iframe {
    border-radius: 0 0 1rem 1rem;
}

/* ── Button ripple effect ── */
button, a {
    -webkit-tap-highlight-color: transparent;
}

/* ── Utility: geometric accent shapes ── */
.geo-circle {
    border-radius: 50%;
}

.geo-square {
    border-radius: 0.5rem;
}

.geo-triangle {
    clip-path: polygon(50% 0%, 0% 100%, 100% 100%);
}

.geo-diamond {
    clip-path: polygon(50% 0%, 100% 50%, 50% 100%, 0% 50%);
}

/* ── Print styles ── */
@media print {
    #navbar, #bg-canvas, .reveal { display: none; }
    body { background: white; color: black; }
    a { color: black; }
}
