/* ============================================
   STONEMADE INK — Custom Styles
   ============================================ */

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

html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    overflow-x: hidden;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 6px;
}
::-webkit-scrollbar-track {
    background: #fefdf8;
}
::-webkit-scrollbar-thumb {
    background: #065f46;
    border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
    background: #047857;
}

/* Selection */
::selection {
    background: #065f46;
    color: #fefdf8;
}

/* ============================================
   NAVIGATION
   ============================================ */
.nav-link {
    position: relative;
}

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

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

/* Navbar scroll state */
nav.scrolled {
    background: rgba(254, 253, 248, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 rgba(6, 95, 70, 0.08);
}

nav.scrolled .nav-text {
    color: #065f46;
}

nav.scrolled .nav-link {
    color: #065f46;
}

nav.scrolled #line1,
nav.scrolled #line2,
nav.scrolled #line3 {
    background: #065f46;
}

/* Mobile menu animation */
#mobile-menu.open {
    opacity: 1;
    pointer-events: all;
}

#mobile-menu.closed {
    opacity: 0;
    pointer-events: none;
}

/* Hamburger to X */
#menu-icon.active #line1 {
    transform: translateY(4px) rotate(45deg);
}
#menu-icon.active #line2 {
    opacity: 0;
    transform: translateX(-8px);
}
#menu-icon.active #line3 {
    transform: translateY(-4px) rotate(-45deg);
}

/* ============================================
   HERO ANIMATIONS
   ============================================ */
.hero-eyebrow {
    animation: slideUp 0.8s ease forwards;
    animation-delay: 0.2s;
    opacity: 0;
    transform: translateY(20px);
}

.hero-title {
    animation: slideUp 0.8s ease forwards;
    animation-delay: 0.4s;
    opacity: 0;
    transform: translateY(20px);
}

.hero-desc {
    animation: slideUp 0.8s ease forwards;
    animation-delay: 0.6s;
    opacity: 0;
    transform: translateY(20px);
}

@keyframes slideUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Floating cards */
.floating-card-1 {
    animation: float1 6s ease-in-out infinite;
}

.floating-card-2 {
    animation: float2 7s ease-in-out infinite;
}

.floating-card-3 {
    animation: float3 5s ease-in-out infinite;
}

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

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

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

/* Scroll line animation */
@keyframes scrollLine {
    0% { top: -16px; }
    100% { top: 48px; }
}

.animate-scroll-line {
    animation: scrollLine 1.5s ease-in-out infinite;
}

/* ============================================
   SERVICE CARDS
   ============================================ */
.service-card {
    transition: transform 0.5s ease, background 0.5s ease;
}

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

/* ============================================
   GALLERY
   ============================================ */
.gallery-item {
    cursor: pointer;
    position: relative;
}

.gallery-item::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(6, 78, 59, 0);
    transition: background 0.4s ease;
}

.gallery-item:hover::after {
    background: rgba(6, 78, 59, 0.1);
}

/* ============================================
   TESTIMONIAL CARDS
   ============================================ */
.testimonial-card {
    transition: transform 0.5s ease, box-shadow 0.5s ease;
}

.testimonial-card:hover {
    transform: translateY(-6px);
}

/* ============================================
   SCROLL REVEAL
   ============================================ */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

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

.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }
.reveal-delay-5 { transition-delay: 0.5s; }
.reveal-delay-6 { transition-delay: 0.6s; }

/* ============================================
   FORM STYLES
   ============================================ */
select option {
    background: #064e3b;
    color: #fefdf8;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 767px) {
    .floating-card-1,
    .floating-card-2,
    .floating-card-3 {
        display: none;
    }
}

@media (min-width: 768px) and (max-width: 1023px) {
    .floating-card-3 {
        display: none;
    }
}

/* ============================================
   REDUCED MOTION
   ============================================ */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .reveal {
        opacity: 1;
        transform: none;
    }
}
