/* === CertiGen base styles === */

:root {
    --brand: #fbbf24;
    --brand-dark: #f59e0b;
    --bg: #020617;
    --sidebar-w: 16rem;
}

html { scroll-behavior: smooth; }

body {
    background:
        radial-gradient(circle at 15% 20%, rgba(251,191,36,0.08), transparent 40%),
        radial-gradient(circle at 85% 80%, rgba(59,130,246,0.08), transparent 40%),
        #020617;
    background-attachment: fixed;
}

/* Custom scrollbar */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: #0f172a; }
::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #f59e0b, #b45309);
    border-radius: 6px;
}
::-webkit-scrollbar-thumb:hover { background: #fbbf24; }

/* ===== Sidebar layout ===== */
/* Push main content to the right when sidebar is open (desktop only) */
@media (min-width: 1024px) {
    html.sidebar-open #main-content {
        margin-left: var(--sidebar-w);
    }
}
#main-content {
    transition: margin-left 0.3s ease;
    padding-top: 1rem;
}

/* When sidebar is open, slide it into view */
html.sidebar-open #sidebar {
    transform: translateX(0);
}

/* Show backdrop on mobile when sidebar is open */
@media (max-width: 1023px) {
    html.sidebar-open #sidebarBackdrop {
        display: block;
    }
}

/* Toggle button slides with sidebar on desktop */
@media (min-width: 1024px) {
    html.sidebar-open #sidebarToggle {
        left: calc(var(--sidebar-w) - 3.25rem);
    }
}

/* Add top spacing so toggle button doesn't overlap content */
#main-content > section:first-child,
#main-content > div:first-child {
    padding-top: 4rem;
}

/* Utility animations */
@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50%      { transform: translateY(-12px); }
}
.animate-float { animation: float 5s ease-in-out infinite; }

@keyframes shimmer {
    0%   { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}
.shimmer-text {
    background: linear-gradient(90deg, #fbbf24, #fff, #fbbf24);
    background-size: 200% 100%;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    animation: shimmer 4s linear infinite;
}

@keyframes fadeUp {
    from { opacity: 0; transform: translateY(24px); }
    to   { opacity: 1; transform: translateY(0); }
}
.fade-up { animation: fadeUp 0.7s ease forwards; }
.fade-up-delay-1 { animation: fadeUp 0.7s ease 0.15s forwards; opacity: 0; }
.fade-up-delay-2 { animation: fadeUp 0.7s ease 0.3s forwards; opacity: 0; }
.fade-up-delay-3 { animation: fadeUp 0.7s ease 0.45s forwards; opacity: 0; }

/* Glassy card */
.glass {
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.08);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

/* Gradient border on hover */
.card-hover {
    position: relative;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.card-hover:hover {
    transform: translateY(-6px);
    box-shadow: 0 25px 60px -20px rgba(251,191,36,0.25);
}

/* Hero grid pattern */
.grid-bg {
    background-image:
        linear-gradient(rgba(255,255,255,0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.04) 1px, transparent 1px);
    background-size: 40px 40px;
    mask-image: radial-gradient(ellipse at center, black 40%, transparent 70%);
    -webkit-mask-image: radial-gradient(ellipse at center, black 40%, transparent 70%);
}
