/* ===== CSS Custom Properties ===== */
:root {
    --midnight-950: #0f1d4a;
    --midnight-900: #1e3a8a;
    --midnight-800: #3b5bdb;
    --mint-400: #4ade80;
    --mint-500: #22c55e;
    --mint-600: #16a34a;
}

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

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

body {
    margin: 0;
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
}

/* ===== Geometric Background Shapes ===== */
.geo-shape {
    position: absolute;
    pointer-events: none;
    opacity: 0.06;
}

.geo-triangle-1 {
    top: 15%;
    right: 5%;
    width: 0;
    height: 0;
    border-left: 80px solid transparent;
    border-right: 80px solid transparent;
    border-bottom: 140px solid var(--mint-400);
    transform: rotate(15deg);
    animation: float 8s ease-in-out infinite;
}

.geo-square-1 {
    top: 60%;
    left: 3%;
    width: 100px;
    height: 100px;
    background: var(--mint-400);
    border-radius: 16px;
    transform: rotate(45deg);
    animation: float 10s ease-in-out infinite reverse;
}

.geo-circle-1 {
    bottom: 20%;
    right: 10%;
    width: 120px;
    height: 120px;
    border: 3px solid var(--mint-400);
    border-radius: 50%;
    animation: float 7s ease-in-out infinite;
}

.geo-triangle-2 {
    top: 40%;
    left: 8%;
    width: 0;
    height: 0;
    border-left: 50px solid transparent;
    border-right: 50px solid transparent;
    border-bottom: 87px solid var(--midnight-500);
    transform: rotate(-20deg);
    animation: float 9s ease-in-out infinite reverse;
}

.geo-rect-1 {
    top: 75%;
    right: 15%;
    width: 60px;
    height: 140px;
    background: var(--mint-400);
    border-radius: 12px;
    transform: rotate(30deg);
    animation: float 11s ease-in-out infinite;
}

.geo-diamond-1 {
    top: 20%;
    right: -5%;
    width: 200px;
    height: 200px;
    background: var(--mint-400);
    border-radius: 24px;
    transform: rotate(45deg);
    opacity: 0.03;
    animation: pulse-slow 6s ease-in-out infinite;
}

.geo-line-1 {
    bottom: 10%;
    left: 0;
    width: 300px;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--mint-400), transparent);
    opacity: 0.1;
}

/* ===== Floating Cards ===== */
.floating-card {
    animation: float 4s ease-in-out infinite;
}

.card-stat-1 {
    animation-delay: 0s;
}

.card-stat-2 {
    animation-delay: 1s;
}

.card-stat-3 {
    animation-delay: 2s;
}

/* ===== Animations ===== */
@keyframes float {
    0%, 100% {
        transform: translateY(0px) rotate(var(--rotation, 0deg));
    }
    50% {
        transform: translateY(-20px) rotate(var(--rotation, 0deg));
    }
}

@keyframes float-simple {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-15px);
    }
}

@keyframes pulse-slow {
    0%, 100% {
        opacity: 0.03;
        transform: rotate(45deg) scale(1);
    }
    50% {
        opacity: 0.06;
        transform: rotate(45deg) scale(1.05);
    }
}

.card-stat-1 { --rotation: 0deg; animation-name: float-simple; }
.card-stat-2 { --rotation: 0deg; animation-name: float-simple; animation-duration: 5s; }
.card-stat-3 { --rotation: 0deg; animation-name: float-simple; animation-duration: 6s; }

/* ===== Scroll Reveal ===== */
.scroll-reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

@media (prefers-reduced-motion: no-preference) {
    .scroll-reveal {
        opacity: 0;
        transform: translateY(30px);
        transition: opacity 0.7s ease, transform 0.7s ease;
    }
    
    .scroll-reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }
    
    .scroll-reveal:nth-child(2) { transition-delay: 0.1s; }
    .scroll-reveal:nth-child(3) { transition-delay: 0.2s; }
    .scroll-reveal:nth-child(4) { transition-delay: 0.3s; }
    .scroll-reveal:nth-child(5) { transition-delay: 0.4s; }
    .scroll-reveal:nth-child(6) { transition-delay: 0.5s; }
}

/* ===== Service Cards ===== */
.service-card {
    position: relative;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.service-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 60px rgba(74, 222, 128, 0.08);
}

/* ===== Feature Cards ===== */
.feature-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature-card:hover {
    transform: translateX(4px);
}

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

.gallery-item img {
    transition: transform 0.7s ease;
}

/* ===== Navbar ===== */
#navbar {
    background: transparent;
}

#navbar.scrolled {
    background: rgba(15, 29, 74, 0.95);
    backdrop-blur-xl;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

#navbar.scrolled .logo-text {
    color: #ffffff;
}

/* ===== Mobile Menu ===== */
.menu-line {
    transition: all 0.3s ease;
}

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

#menu-btn.active .menu-line:nth-child(2) {
    opacity: 0;
}

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

/* ===== Custom Select ===== */
select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%234ade80' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 36px;
}

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

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

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

::-webkit-scrollbar-thumb:hover {
    background: #4ade80;
}

/* ===== Selection ===== */
::selection {
    background: rgba(74, 222, 128, 0.3);
    color: #ffffff;
}

/* ===== Focus Visible ===== */
:focus-visible {
    outline: 2px solid #4ade80;
    outline-offset: 2px;
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
    .geo-triangle-1,
    .geo-square-1,
    .geo-circle-1,
    .geo-triangle-2,
    .geo-rect-1,
    .geo-diamond-1 {
        display: none;
    }
    
    .floating-card.card-stat-3 {
        display: none;
    }
}
