/* ===== Base & Typography ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

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

body {
    font-family: 'Inter', sans-serif;
    background-color: #0a0a0f;
    color: #ffffff;
    overflow-x: hidden;
}

.font-display {
    font-family: 'Playfair Display', serif;
}

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

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

@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(30px);
    }

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

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

#navbar.scrolled {
    background: rgba(10, 10, 15, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.05);
}

.nav-line {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

#mobile-toggle.active .nav-line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

#mobile-toggle.active .nav-line:nth-child(2) {
    opacity: 0;
    transform: translateX(10px);
}

#mobile-toggle.active .nav-line:nth-child(3) {
    width: 24px;
    transform: rotate(-45deg) translate(5px, -5px);
}

.mobile-link {
    display: block;
}

/* ===== Floating Cards Animation ===== */
@media (prefers-reduced-motion: no-preference) {
    .floating-card-1 {
        animation: float1 4s ease-in-out infinite;
    }

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

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

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

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

::-webkit-scrollbar-track {
    background: #0a0a0f;
}

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

::-webkit-scrollbar-thumb:hover {
    background: #fbbf24;
}

/* ===== Selection ===== */
::selection {
    background: rgba(251, 191, 36, 0.3);
    color: #ffffff;
}

/* ===== Button Focus ===== */
a:focus-visible, button:focus-visible {
    outline: 2px solid #fbbf24;
    outline-offset: 2px;
    border-radius: 4px;
}

/* ===== Image Loading ===== */
img {
    image-rendering: auto;
}

img[loading="lazy"] {
    opacity: 0;
    transition: opacity 0.5s ease;
}

img[loading="lazy"].loaded {
    opacity: 1;
}

/* ===== Service Card Hover ===== */
.group:hover .group-hover\:from-amber-400 {
    background: linear-gradient(135deg, rgba(251, 191, 36, 0.3) 0%, rgba(217, 119, 6, 0.15) 100%);
}

.group:hover .group-hover\:from-plum-500 {
    background: linear-gradient(135deg, rgba(236, 72, 153, 0.3) 0%, rgba(157, 23, 77, 0.15) 100%);
}
