/* ============================================================
   SDS Elite — app.css
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

/* ---- Loading Bar ---- */

#sds-loader {
    position: fixed;
    top: 0; left: 0; right: 0;
    height: 3px;
    z-index: 9999;
    transition: opacity .3s;
}

#sds-loader-bar {
    height: 100%;
    width: 0%;
    background: var(--accent, #06b6d4);
    transition: width .12s ease-out;
    border-radius: 0 2px 2px 0;
    box-shadow: 0 0 8px rgba(6,182,212,.6);
}

/* ---- Reset & Base ---- */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --navy:    #0f1f3d;
    --blue:    #1a56db;
    --accent:  #06b6d4;
    --text:    #1e293b;
    --muted:   #64748b;
    --light:   #f8fafc;
    --border:  #e2e8f0;
    --white:   #ffffff;
    --radius:  8px;
    --shadow:  0 1px 3px rgba(0,0,0,.08), 0 4px 16px rgba(0,0,0,.06);
    --shadow-md: 0 4px 6px rgba(0,0,0,.07), 0 10px 30px rgba(0,0,0,.08);
}

html {
    scroll-behavior: smooth;
}

html, body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    font-size: 16px;
    color: var(--text);
    background: var(--white);
    -webkit-font-smoothing: antialiased;
}

a { color: var(--blue); }
a:hover { color: #1347b8; }

/* ---- Hero fade-in ---- */

@keyframes fadeUp {
    from { opacity: 0; transform: translateY(18px); }
    to   { opacity: 1; transform: translateY(0); }
}

.hero-animate {
    animation: fadeUp .65s ease both;
}
.hero-animate-delay-1 { animation-delay: .1s; }
.hero-animate-delay-2 { animation-delay: .22s; }
.hero-animate-delay-3 { animation-delay: .36s; }

/* ---- Layout Shell ---- */

.sds-layout {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.sds-main {
    flex: 1;
}

/* ---- Navigation ---- */

.sds-header {
    position: sticky;
    top: 0;
    z-index: 200;
    background: rgba(15, 31, 61, 0.97);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    box-shadow: 0 1px 0 rgba(255,255,255,.07), 0 2px 12px rgba(0,0,0,.25);
}

.sds-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1040px;
    margin: 0 auto;
    padding: 0 24px;
    height: 60px;
}

.sds-nav-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--white);
    font-size: 1.05rem;
    font-weight: 600;
    letter-spacing: -.01em;
}

.sds-nav-brand:hover { color: var(--accent); text-decoration: none; }

.sds-nav-brand img {
    height: 34px;
    width: auto;
    display: block;
    /* The cloud logo is dark-on-light, so it vanishes on the dark header.
       Seat it on a clean white chip so it reads crisply. */
    background: #fff;
    border-radius: 8px;
    padding: 3px 7px;
    box-shadow: 0 1px 4px rgba(0,0,0,.3);
}

.sds-nav-links {
    display: flex;
    align-items: center;
    gap: 32px;
}

.sds-nav-link {
    color: rgba(255,255,255,.75);
    text-decoration: none;
    font-size: .875rem;
    font-weight: 500;
    transition: color .15s;
    letter-spacing: .01em;
}

.sds-nav-link:hover,
.sds-nav-link.active {
    color: var(--white);
    text-decoration: none;
}

/* ---- Hero ---- */

.sds-hero {
    position: relative;
    overflow: hidden;
    background: linear-gradient(150deg, #0a1628 0%, #0f2147 45%, #1a3a6b 80%, #1e4fa8 100%);
    color: var(--white);
    padding: 100px 24px 92px;
    text-align: center;
}

/* Subtle dot grid overlay */
.sds-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: radial-gradient(circle, rgba(255,255,255,.065) 1px, transparent 1px);
    background-size: 28px 28px;
    pointer-events: none;
}

/* Soft glow orb */
.sds-hero::after {
    content: '';
    position: absolute;
    top: -80px;
    left: 50%;
    transform: translateX(-50%);
    width: 600px;
    height: 600px;
    background: radial-gradient(ellipse, rgba(6,182,212,.12) 0%, transparent 70%);
    pointer-events: none;
}

.sds-hero-content {
    position: relative;
    z-index: 1;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    background: rgba(6,182,212,.15);
    border: 1px solid rgba(6,182,212,.3);
    color: var(--accent);
    font-size: .78rem;
    font-weight: 600;
    letter-spacing: .06em;
    text-transform: uppercase;
    padding: 6px 14px;
    border-radius: 20px;
    margin-bottom: 24px;
}

.hero-badge-dot {
    width: 6px;
    height: 6px;
    background: var(--accent);
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: .4; }
}

.sds-hero h1 {
    font-size: clamp(2.1rem, 5.5vw, 3.4rem);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -.035em;
    color: var(--white);
    margin-bottom: 22px;
}

.sds-hero h1 .accent {
    color: var(--accent);
}

.hero-sub {
    font-size: 1.15rem;
    line-height: 1.7;
    opacity: .8;
    max-width: 580px;
    margin: 0 auto 40px;
    font-weight: 400;
}

/* ---- CTA Button ---- */

.cta-button {
    display: inline-block;
    background: var(--accent);
    color: var(--navy);
    font-weight: 700;
    font-size: .95rem;
    padding: 14px 32px;
    border-radius: var(--radius);
    text-decoration: none;
    letter-spacing: .01em;
    transition: background .15s, transform .12s, box-shadow .15s;
    box-shadow: 0 4px 14px rgba(6,182,212,.35);
}

.cta-button:hover {
    background: #08d4f0;
    color: var(--navy);
    text-decoration: none;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(6,182,212,.45);
}

/* ---- Stats Bar ---- */

.sds-stats {
    background: var(--light);
    border-bottom: 1px solid var(--border);
    padding: 28px 24px;
}

.sds-stats-inner {
    max-width: 960px;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    gap: 64px;
    flex-wrap: wrap;
}

.sds-stat {
    text-align: center;
}

.sds-stat-number {
    display: block;
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--navy);
    letter-spacing: -.03em;
    line-height: 1;
    margin-bottom: 4px;
}

.sds-stat-label {
    font-size: .78rem;
    font-weight: 500;
    color: var(--muted);
    letter-spacing: .04em;
    text-transform: uppercase;
}

/* ---- Page Sections ---- */

.sds-section {
    padding: 68px 0 76px;
}

.sds-container {
    max-width: 960px;
    margin: 0 auto;
    padding: 0 24px;
}

.sds-divider {
    border: none;
    border-top: 1px solid var(--border);
    margin: 56px 0;
}

.section-title {
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--navy);
    letter-spacing: -.025em;
    margin-bottom: 8px;
}

.section-subtitle {
    font-size: .95rem;
    color: var(--muted);
    margin-bottom: 32px;
    line-height: 1.6;
}

/* ---- About Block ---- */

.sds-about {
    margin-bottom: 8px;
}

.sds-about h2 {
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--navy);
    letter-spacing: -.025em;
    margin-bottom: 18px;
}

.sds-about p {
    font-size: 1rem;
    line-height: 1.8;
    color: var(--text);
    margin-bottom: 14px;
    max-width: 780px;
}

/* ---- Services Grid ---- */

.sds-services {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(215px, 1fr));
    gap: 18px;
}

.sds-service-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-top: 3px solid var(--blue);
    border-radius: var(--radius);
    padding: 28px 22px 24px;
    transition: box-shadow .2s, transform .2s;
}

.sds-service-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-3px);
}

.sds-service-card.sds-service-highlight {
    border-top-color: var(--accent);
    background: #f0fafb;
}

.service-icon {
    width: 36px;
    height: 36px;
    margin-bottom: 14px;
    color: var(--blue);
    flex-shrink: 0;
}

.sds-service-highlight .service-icon {
    color: #0e7490;
}

.sds-service-card h3 {
    font-size: .95rem;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: 10px;
    letter-spacing: -.01em;
}

.sds-service-card.sds-service-highlight h3 {
    color: #0e7490;
}

.sds-service-card p {
    font-size: .875rem;
    line-height: 1.65;
    color: var(--muted);
    margin: 0;
}

/* ---- Projects ---- */

.sds-projects {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.sds-project {
    background: var(--white);
    border: 1px solid var(--border);
    border-left: 4px solid var(--blue);
    border-radius: var(--radius);
    padding: 28px 28px 24px;
    transition: box-shadow .2s, border-left-color .2s;
}

.sds-project:hover {
    box-shadow: var(--shadow-md);
    border-left-color: var(--accent);
}

.sds-project h3 {
    font-size: 1.02rem;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: 10px;
    letter-spacing: -.01em;
}

.sds-project p {
    font-size: .925rem;
    line-height: 1.75;
    color: var(--text);
    margin-bottom: 16px;
}

.tech-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.tech-tags span {
    background: #eef2ff;
    color: #3730a3;
    font-size: .72rem;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: 20px;
    letter-spacing: .02em;
}

/* ---- CTA Block ---- */

.sds-cta-block {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #0a1628 0%, #0f2147 50%, #1a3a6b 100%);
    color: var(--white);
    border-radius: 12px;
    padding: 56px 40px;
    text-align: center;
    border: 1px solid rgba(255,255,255,.07);
}

.sds-cta-block::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: radial-gradient(circle, rgba(255,255,255,.05) 1px, transparent 1px);
    background-size: 24px 24px;
    pointer-events: none;
}

.sds-cta-block h2 {
    position: relative;
    font-size: 2rem;
    font-weight: 800;
    color: var(--white);
    letter-spacing: -.035em;
    margin-bottom: 14px;
}

.sds-cta-block p {
    position: relative;
    font-size: 1rem;
    opacity: .8;
    max-width: 520px;
    margin: 0 auto 30px;
    line-height: 1.7;
}

.cta-sub {
    position: relative;
    margin-top: 18px;
    font-size: .875rem;
    opacity: .5;
}

/* ---- Footer ---- */

.sds-footer {
    background: #080f1e;
    color: rgba(255,255,255,.45);
    padding: 28px 24px;
    font-size: .85rem;
    border-top: 1px solid rgba(255,255,255,.06);
}

.sds-footer-inner {
    max-width: 960px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    justify-content: center;
}

.footer-logo {
    height: 24px;
    width: auto;
    background: #fff;
    border-radius: 5px;
    padding: 2px 5px;
    opacity: .9;
}

.sds-footer a {
    color: rgba(255,255,255,.45);
    text-decoration: none;
    transition: color .15s;
}

.sds-footer a:hover { color: var(--white); }

/* ---- Blazor Error UI ---- */

#blazor-error-ui {
    background: lightyellow;
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0,0,0,.2);
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
    color-scheme: light only;
}

#blazor-error-ui .dismiss { cursor: pointer; position: absolute; right: 0.75rem; top: 0.5rem; }

.blazor-error-boundary { background: url("data:image/svg+xml,...") no-repeat 1rem/1.8rem, #b32121; padding: 1rem 1rem 1rem 3.7rem; color: white; }
.blazor-error-boundary::after { content: "An error has occurred." }

.loading-progress {
    position: relative;
    display: block;
    width: 8rem;
    height: 8rem;
    margin: 20vh auto 1rem;
}

.loading-progress circle {
    fill: none;
    stroke: #e0e0e0;
    stroke-width: 0.6rem;
    transform-origin: 50% 50%;
    transform: rotate(-90deg);
}

.loading-progress circle:last-child {
    stroke: var(--blue);
    stroke-dasharray: calc(3.141 * var(--blazor-load-percentage, 0%) * 0.8), 500%;
    transition: stroke-dasharray 0.05s ease-in-out;
}

.loading-progress-text {
    position: absolute;
    text-align: center;
    font-weight: 600;
    inset: calc(20vh + 3.25rem) 0 auto;
    opacity: 0.4;
}

.loading-progress-text:after { content: var(--blazor-load-percentage-text, "Loading"); }

/* ---- Responsive ---- */

@media (max-width: 640px) {
    .sds-hero { padding: 72px 20px 64px; }
    .sds-hero h1 { font-size: 2rem; letter-spacing: -.025em; }
    .hero-sub { font-size: 1rem; }
    .sds-services { grid-template-columns: 1fr; }
    .sds-cta-block { padding: 40px 24px; }
    .sds-cta-block h2 { font-size: 1.6rem; }
    .sds-stats-inner { gap: 32px; }
    .sds-stat-number { font-size: 1.5rem; }

    /* Header: stack the brand above the links so the full company name
       never overflows or crowds the nav on narrow screens. */
    .sds-nav {
        flex-wrap: wrap;
        height: auto;
        padding: 10px 16px;
        row-gap: 8px;
    }
    .sds-nav-brand {
        flex: 1 1 100%;
        font-size: .9rem;
        gap: 8px;
    }
    .sds-nav-brand img { height: 28px; }
    .sds-nav-links {
        flex: 1 1 100%;
        flex-wrap: wrap;
        gap: 12px 18px;
        justify-content: flex-start;
    }
}
