/* portfolio.css — professional portfolio layer over Minty theme
    Loads after styles.css; does not modify styles.css
   ================================================================= */


/* 1. Google Fonts ======================================================= */

@import url('https://fonts.googleapis.com/css2?family=DM+Sans:opsz,wght@9..40,400;9..40,500;9..40,600;9..40,700&family=Inter:wght@400;500;600&family=JetBrains+Mono:wght@400;500;600&display=swap');


/* 2. Design Tokens ======================================================= */

:root {
    /* teal palette */
    --pf-primary:        #0d9488;
    --pf-primary-hover:  #0f766e;
    --pf-primary-light:  #f0fdf9;
    --pf-primary-mid:    #5eead4;
    --pf-accent:         #069dd4;  /* cyan accent for coder flair */

    /* neutrals */
    --pf-text:           #0f172a;
    --pf-text-secondary: #475569;
    --pf-text-muted:     #94a3b8;
    --pf-surface:        #f8fafc;
    --pf-card:           #ffffff;
    --pf-border:         #e2e8f0;
    --pf-border-subtle:  #f1f5f9;

    /* elevation */
    --pf-shadow:         0 1px 4px rgba(0,0,0,0.06), 0 0 0 1px rgba(0,0,0,0.04);
    --pf-shadow-hover:   0 8px 24px rgba(13,148,136,0.12), 0 2px 8px rgba(0,0,0,0.08);
    --pf-glow:           0 0 0 3px rgba(13,148,136,0.18), 0 0 16px rgba(13,148,136,0.10);

    /* shape */
    --pf-radius:         10px;
    --pf-radius-sm:      6px;
    --pf-radius-pill:    999px;

    /* code aesthetic */
    --pf-mono:           'JetBrains Mono', 'Fira Code', 'Cascadia Code', monospace;

    /* gradient */
    --pf-gradient:       linear-gradient(135deg, #0d9488 0%, #06b6d4 50%, #0d9488 100%);
    --pf-gradient-text:  linear-gradient(135deg, #0f766e 0%, #0891b2 60%, #0d9488 100%);
}


/* ── Global selection color ─────────────────────────────────────── */
::selection {
    background-color: rgba(13, 148, 136, 0.18);
    color: var(--pf-text);
}

/* ── Scrollbar (Webkit) ─────────────────────────────────────────── */
::-webkit-scrollbar       { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: var(--pf-surface); }
::-webkit-scrollbar-thumb { background: var(--pf-primary); border-radius: 99px; }
::-webkit-scrollbar-thumb:hover { background: var(--pf-primary-hover); }


/* 3. Base Typography ===================================================== */

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    color: var(--pf-text);
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'DM Sans', system-ui, -apple-system, sans-serif;
    color: var(--pf-text);
    line-height: 1.25;
    letter-spacing: -0.01em;
}

h1 { font-size: clamp(1.8rem, 4vw, 2.5rem); font-weight: 700; }
h2 { font-size: clamp(1.35rem, 2.5vw, 1.75rem); font-weight: 600; }
h3 { font-size: 1.2rem; font-weight: 600; }
h4 { font-size: 1.05rem; font-weight: 600; }

p { margin-bottom: 1rem; }

a {
    color: var(--pf-primary);
    text-decoration-color: transparent;
    transition: color 0.15s, text-decoration-color 0.15s;
}
a:hover {
    color: var(--pf-primary-hover);
    text-decoration-color: var(--pf-primary-hover);
}


/* 4. Navbar ============================================================== */

.navbar {
    border-bottom: 1px solid var(--pf-border);
    background-color: rgba(255,255,255,0.92) !important;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(0,0,0,0.05);
    position: sticky;
    top: 0;
    z-index: 1000;
}

/* terminal prompt before brand name */
.navbar-brand {
    font-family: var(--pf-mono);
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--pf-text) !important;
    letter-spacing: -0.01em;
    display: flex;
    align-items: center;
    gap: 0;
}
.navbar-brand::before {
    content: '>_ ';
    font-family: var(--pf-mono);
    color: var(--pf-primary);
    font-weight: 400;
    margin-right: 0.35em;
    opacity: 0.85;
}
.navbar-brand:hover { color: var(--pf-primary) !important; }
.navbar-brand:hover::before { opacity: 1; }

.navbar-nav .nav-link {
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    font-size: 0.9rem;
    color: var(--pf-text-secondary) !important;
    padding: 0.35rem 0.75rem !important;
    border-radius: var(--pf-radius-sm);
    transition: color 0.15s, background 0.15s;
    position: relative;
}
/* animated underline indicator */
.navbar-nav .nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    border-radius: 2px;
    background: var(--pf-gradient);
    transition: width 0.22s ease;
}
.navbar-nav .nav-link:hover::after,
.navbar-nav .nav-link.active::after {
    width: calc(100% - 1.5rem);
}
.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
    color: var(--pf-primary) !important;
    background-color: var(--pf-primary-light);
}

/* --- toggle button ----------------------------------------------------- */
.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='%230d9488' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}


/* 5. Home Hero =========================================================== */

/* dot-grid on the page body — fixed so it tiles the whole viewport
   without masking any content; opacity is intentionally very low     */
body {
    background-color: #ffffff;
    background-image:
        radial-gradient(circle, rgba(13,148,136,0.07) 1px, transparent 1px);
    background-size: 22px 22px;
    background-attachment: fixed;
}

/* keep content surfaces clearly white so dots read as subtle texture */
#quarto-content,
#quarto-document-content,
main.content,
.quarto-title-block,
.featured-card,
#quarto-sidebar,
#quarto-margin-sidebar,
.navbar,
.nav-footer {
    background-color: #ffffff;
}

body:not(.quarto-sidebar-visible) .quarto-title-block {
    padding: 1.2rem 0 1rem;
    border-bottom: none;
    position: relative;
}

/* gradient animated title on the home page */
body:not(.quarto-sidebar-visible) .quarto-title h1.title {
    font-size: clamp(2rem, 5vw, 3.2rem);
    font-weight: 700;
    margin-bottom: 0.4rem;
    background: var(--pf-gradient-text);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradient-pan 5s ease infinite;
    letter-spacing: -0.02em;
}

/* typing cursor appended to the title */
body:not(.quarto-sidebar-visible) .quarto-title h1.title::after {
    content: '|';
    -webkit-text-fill-color: var(--pf-primary-mid);
    font-weight: 300;
    margin-left: 2px;
    animation: blink-cursor 1.1s step-end infinite;
}

body:not(.quarto-sidebar-visible) .quarto-title p.subtitle {
    font-family: var(--pf-mono);
    font-size: 0.95rem;
    color: var(--pf-text-secondary);
    font-weight: 400;
    margin-bottom: 0;
    letter-spacing: 0.01em;
    opacity: 0.85;
}
/* add a "# " comment prefix to the subtitle */
body:not(.quarto-sidebar-visible) .quarto-title p.subtitle::before {
    content: '# ';
    color: var(--pf-primary-mid);
    font-weight: 600;
}

/* intro paragraph below the title block */
#quarto-content .quarto-title-block + p,
.quarto-title-block ~ p:first-of-type {
    font-size: 1.05rem;
    color: var(--pf-text-secondary);
    line-height: 1.7;
    margin-top: 1.75rem;
}

/* "Featured Projects" heading */
#featured-projects {
    margin-top: 2.5rem;
}
#featured-projects h2,
h2#featured-projects {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--pf-text-muted);
    margin-bottom: 1.25rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--pf-border);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
/* data-chart bar accent before section headings */
h2#featured-projects::before,
#featured-projects h2::before {
    content: '';
    display: inline-block;
    width: 3px;
    height: 0.9em;
    background: var(--pf-gradient);
    border-radius: 2px;
    flex-shrink: 0;
}


/* 6. Featured Project Cards ============================================== */

.featured-card {
    background: var(--pf-card);
    border: 1px solid var(--pf-border);
    border-radius: var(--pf-radius);
    padding: 1.4rem 1.5rem 1.4rem 1.75rem;
    box-shadow: var(--pf-shadow);
    transition: box-shadow 0.22s ease, transform 0.22s ease, border-color 0.22s ease;
    cursor: default;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    position: relative;
    overflow: hidden;
}
/* teal left-border accent — appears on hover */
.featured-card::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: var(--pf-gradient);
    opacity: 0;
    transition: opacity 0.22s ease;
    border-radius: var(--pf-radius) 0 0 var(--pf-radius);
}
/* subtle top-right corner glow */
.featured-card::after {
    content: '';
    position: absolute;
    top: -40px;
    right: -40px;
    width: 100px;
    height: 100px;
    background: radial-gradient(circle, rgba(94,234,212,0.12) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}
.featured-card:hover {
    box-shadow: var(--pf-shadow-hover);
    transform: translateY(-3px);
    border-color: rgba(13,148,136,0.25);
}
.featured-card:hover::before { opacity: 1; }
.featured-card:hover::after  { opacity: 1; }

/* project title link */
.featured-card > p:first-child a,
.featured-card p:first-child strong a,
.featured-card a strong {
    font-family: 'DM Sans', sans-serif;
    font-weight: 600;
    font-size: 1rem;
    color: var(--pf-text);
    text-decoration: none;
    transition: color 0.15s;
}
.featured-card > p:first-child a:hover,
.featured-card p:first-child strong a:hover,
.featured-card a strong:hover {
    color: var(--pf-primary);
    text-decoration: none;
}

/* description text */
.featured-card p {
    font-size: 0.88rem;
    color: var(--pf-text-secondary);
    line-height: 1.55;
    margin: 0;
}

/* tech badge tags (backtick `Python`) */
.featured-card code {
    font-family: var(--pf-mono);
    font-size: 0.70rem;
    font-weight: 500;
    background: var(--pf-primary-light);
    color: var(--pf-primary-hover);
    border-radius: var(--pf-radius-pill);
    padding: 0.15rem 0.6rem;
    letter-spacing: 0.02em;
    border: 1px solid rgba(13,148,136,0.15);
    transition: background 0.15s, color 0.15s;
}
.featured-card:hover code {
    background: rgba(13,148,136,0.12);
    color: var(--pf-primary-hover);
}

.grid {
    gap: 1rem;
    margin-top: 0.25rem;
}


/* 7. CTA Buttons ========================================================= */

.btn-primary {
    background: var(--pf-gradient) !important;
    background-size: 200% auto !important;
    border: none !important;
    color: #fff !important;
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    font-size: 0.9rem;
    padding: 0.6rem 1.45rem;
    border-radius: var(--pf-radius-sm);
    transition: background-position 0.4s ease, box-shadow 0.15s, transform 0.15s;
    box-shadow: 0 2px 8px rgba(13,148,136,0.25);
    position: relative;
    overflow: hidden;
}
.btn-primary:hover,
.btn-primary:focus {
    background-position: right center !important;
    box-shadow: var(--pf-glow) !important;
    transform: translateY(-1px);
    color: #fff !important;
}

.btn-outline-primary {
    border: 1.5px solid var(--pf-primary) !important;
    color: var(--pf-primary) !important;
    background-color: transparent !important;
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    font-size: 0.9rem;
    padding: 0.6rem 1.45rem;
    border-radius: var(--pf-radius-sm);
    transition: background-color 0.18s, color 0.18s, box-shadow 0.18s, transform 0.15s;
}
.btn-outline-primary:hover,
.btn-outline-primary:focus {
    background-color: var(--pf-primary) !important;
    color: #fff !important;
    box-shadow: var(--pf-glow) !important;
    transform: translateY(-1px);
}


/* 8. Article / Project Page Layout ======================================= */

.quarto-title-block {
    padding-bottom: 1rem;
    /* margin-bottom: 1rem; */
    border-bottom: 1px solid var(--pf-border);
}

.quarto-title h1.title {
    font-weight: 700;
    /* margin-bottom: 0.5rem; */
}

/* author / date meta */
.quarto-title-meta {
    font-size: 0.82rem;
    color: var(--pf-text-muted);
}
.quarto-title-meta-heading {
    font-weight: 600;
    color: var(--pf-text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-size: 0.7rem;
}

/* category pills */
.quarto-title .quarto-categories {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    margin-top: 0.75rem;
}
.quarto-title .quarto-categories .quarto-category {
    font-family: var(--pf-mono);
    font-size: 0.7rem;
    font-weight: 500;
    background: var(--pf-primary-light);
    color: var(--pf-primary-hover) !important;
    border-radius: var(--pf-radius-pill);
    padding: 0.2rem 0.65rem;
    border: 1px solid rgba(13,148,136,0.2);
    transition: background 0.15s;
}
.quarto-title .quarto-categories .quarto-category:hover {
    background: rgba(13,148,136,0.15);
}

/* article section headings — teal bar accent */
.quarto-title-block ~ section h2,
#quarto-document-content h2 {
    margin-top: 2rem;
    padding-top: 0.25rem;
    display: flex;
    align-items: center;
    gap: 0.55rem;
}
.quarto-title-block ~ section h2::before,
#quarto-document-content h2::before {
    content: '';
    display: inline-block;
    width: 3px;
    height: 0.85em;
    background: var(--pf-gradient);
    border-radius: 2px;
    flex-shrink: 0;
    opacity: 0.7;
}
#quarto-document-content h3 {
    margin-top: 1.5rem;
}


/* 9. Sidebar ============================================================= */

#quarto-sidebar {
    background-color: var(--pf-surface) !important;
    border-right: 1px solid var(--pf-border) !important;
    font-size: 0.7rem;
}

.sidebar-menu-container .sidebar-section .sidebar-section-item,
.sidebar .sidebar-section > .sidebar-item,
.quarto-sidebar .sidebar-section-item {
    font-family: var(--pf-mono);
    font-size: 0.68rem;
    font-weight: 600;
    color: var(--pf-text-muted);
    padding: 0 1rem 0.25rem;
}

.sidebar-item-text {
    font-family: 'Inter', sans-serif;
    font-size: 0.85rem;
    color: var(--pf-text-secondary);
    transition: color 0.15s;
}

.sidebar-item-container .sidebar-link:hover .sidebar-item-text {
    color: var(--pf-primary);
}

div.sidebar-item-container .active .sidebar-item-text,
a.sidebar-item-text.sidebar-link.active > .menu-text {
    color: var(--pf-primary) !important;
    font-weight: 500;
}


/* 10. About / Tables ===================================================== */

.quarto-document-content table:not(.dataframe),
#quarto-document-content table:not(.dataframe) {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
    border-radius: var(--pf-radius);
    overflow: hidden;
    box-shadow: var(--pf-shadow);
}
.quarto-document-content table:not(.dataframe) thead tr,
#quarto-document-content table:not(.dataframe) thead tr {
    background: linear-gradient(90deg, #e6f9f6 0%, #f0fdf9 100%);
    color: var(--pf-text);
}
.quarto-document-content table:not(.dataframe) th,
#quarto-document-content table:not(.dataframe) th {
    padding: 0.65rem 0.9rem;
    font-weight: 600;
    font-family: 'DM Sans', sans-serif;
    border-bottom: 2px solid rgba(13,148,136,0.2);
    text-align: left;
}
.quarto-document-content table:not(.dataframe) td,
#quarto-document-content table:not(.dataframe) td {
    padding: 0.55rem 0.9rem;
    border-bottom: 1px solid var(--pf-border);
    color: var(--pf-text-secondary);
}
.quarto-document-content table:not(.dataframe) tbody tr:hover,
#quarto-document-content table:not(.dataframe) tbody tr:hover {
    background-color: var(--pf-primary-light);
}


/* 11. HR and Footer ====================================================== */

hr {
    border: none;
    border-top: 1px solid var(--pf-border);
    margin: 2rem 0;
}

.quarto-other-formats,
.nav-footer {
    font-size: 0.8rem;
    color: var(--pf-text-muted);
}

/* footer: subtle top gradient line */
.nav-footer {
    border-top: 2px solid transparent;
    background-image: linear-gradient(white, white),
                      var(--pf-gradient);
    background-origin: border-box;
    background-clip: padding-box, border-box;
}


/* 12. Code blocks — coder identity ====================================== */

/* ── Code Tools ──────────────────────────────────────────────────────── */
.dropdown-item:hover {
    background-color: var(--pf-primary);
}



/* make inline code monospace with the JetBrains Mono font */
code:not(.sourceCode) {
    font-family: var(--pf-mono) !important;
}

/* source code: subtle terminal gutter */
.sourceCode.cell-code {
    position: relative;
}

/* ── Copy button — override Quarto/Minty hardcoded colors ─────────── */

/* Button shell */
/* .code-copy-button {
    border-radius: var(--pf-radius-sm) !important;
    padding: 2px 5px !important;
    margin-top: 5px !important;
    margin-right: 5px !important;
    background-color: rgba(255,255,255,0.82) !important;
    border: 1px solid var(--pf-border) !important;
    transition: background-color 0.15s, border-color 0.15s, box-shadow 0.15s !important;
}
.code-copy-button:hover {
    background-color: var(--pf-primary-light) !important;
    border-color: rgba(13,148,136,0.35) !important;
    box-shadow: 0 0 0 2px rgba(13,148,136,0.12) !important;
} */

/* Resting icon — muted gray */
/* .code-copy-button > .bi::before {
    background-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%2394a3b8' viewBox='0 0 16 16'><path d='M4 1.5H3a2 2 0 0 0-2 2V14a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2V3.5a2 2 0 0 0-2-2h-1v1h1a1 1 0 0 1 1 1V14a1 1 0 0 1-1 1H3a1 1 0 0 1-1-1V3.5a1 1 0 0 1 1-1h1v-1z'/><path d='M9.5 1a.5.5 0 0 1 .5.5v1a.5.5 0 0 1-.5.5h-3a.5.5 0 0 1-.5-.5v-1a.5.5 0 0 1 .5-.5h3zm-3-1A1.5 1.5 0 0 0 5 1.5v1A1.5 1.5 0 0 0 6.5 4h3A1.5 1.5 0 0 0 11 2.5v-1A1.5 1.5 0 0 0 9.5 0h-3z'/></svg>") !important;
} */
/* Scaffold hover — teal */
/* .code-copy-outer-scaffold:hover > .code-copy-button > .bi::before {
    background-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%230d9488' viewBox='0 0 16 16'><path d='M4 1.5H3a2 2 0 0 0-2 2V14a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2V3.5a2 2 0 0 0-2-2h-1v1h1a1 1 0 0 1 1 1V14a1 1 0 0 1-1 1H3a1 1 0 0 1-1-1V3.5a1 1 0 0 1 1-1h1v-1z'/><path d='M9.5 1a.5.5 0 0 1 .5.5v1a.5.5 0 0 1-.5.5h-3a.5.5 0 0 1-.5-.5v-1a.5.5 0 0 1 .5-.5h3zm-3-1A1.5 1.5 0 0 0 5 1.5v1A1.5 1.5 0 0 0 6.5 4h3A1.5 1.5 0 0 0 11 2.5v-1A1.5 1.5 0 0 0 9.5 0h-3z'/></svg>") !important;
} */
/* Button hover — darker teal */
/* .code-copy-outer-scaffold:hover > .code-copy-button:hover > .bi::before {
    background-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%230f766e' viewBox='0 0 16 16'><path d='M4 1.5H3a2 2 0 0 0-2 2V14a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2V3.5a2 2 0 0 0-2-2h-1v1h1a1 1 0 0 1 1 1V14a1 1 0 0 1-1 1H3a1 1 0 0 1-1-1V3.5a1 1 0 0 1 1-1h1v-1z'/><path d='M9.5 1a.5.5 0 0 1 .5.5v1a.5.5 0 0 1-.5.5h-3a.5.5 0 0 1-.5-.5v-1a.5.5 0 0 1 .5-.5h3zm-3-1A1.5 1.5 0 0 0 5 1.5v1A1.5 1.5 0 0 0 6.5 4h3A1.5 1.5 0 0 0 11 2.5v-1A1.5 1.5 0 0 0 9.5 0h-3z'/></svg>") !important;
} */

/* Checked (copied) states */
/* .code-copy-button-checked > .bi::before {
    background-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%2394a3b8' viewBox='0 0 16 16'><path d='M13.854 3.646a.5.5 0 0 1 0 .708l-7 7a.5.5 0 0 1-.708 0l-3.5-3.5a.5.5 0 1 1 .708-.708L6.5 10.293l6.646-6.647a.5.5 0 0 1 .708 0z'/></svg>") !important;
}
.code-copy-outer-scaffold:hover > .code-copy-button-checked > .bi::before {
    background-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%230d9488' viewBox='0 0 16 16'><path d='M13.854 3.646a.5.5 0 0 1 0 .708l-7 7a.5.5 0 0 1-.708 0l-3.5-3.5a.5.5 0 1 1 .708-.708L6.5 10.293l6.646-6.647a.5.5 0 0 1 .708 0z'/></svg>") !important;
}
.code-copy-outer-scaffold:hover > .code-copy-button-checked:hover > .bi::before {
    background-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%230f766e' viewBox='0 0 16 16'><path d='M13.854 3.646a.5.5 0 0 1 0 .708l-7 7a.5.5 0 0 1-.708 0l-3.5-3.5a.5.5 0 1 1 .708-.708L6.5 10.293l6.646-6.647a.5.5 0 0 1 .708 0z'/></svg>") !important;
} */

/* TOC nav links */
#TOC .nav-link {
    font-size: 0.83rem;
    color: var(--pf-text-secondary);
    transition: color 0.15s, padding-left 0.15s;
}
#TOC .nav-link:hover,
#TOC .nav-link.active {
    color: var(--pf-primary);
    padding-left: 0.2rem;
}
#TOC .nav-link.active {
    font-weight: 500;
    border-left: 2px solid var(--pf-primary);
    padding-left: 0.4rem;
}


/* 13. Keyframe Animations ================================================ */

@keyframes gradient-pan {
    0%   { background-position: 0%   50%; }
    50%  { background-position: 100% 50%; }
    100% { background-position: 0%   50%; }
}

@keyframes blink-cursor {
    0%, 100% { opacity: 1; }
    50%       { opacity: 0; }
}

/* fade-up entrance for cards */
@keyframes fade-up {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}
.featured-card {
    animation: fade-up 0.4s ease both;
}
/* stagger the cards */
.g-col-12:nth-child(1) .featured-card,
.featured-card:nth-child(1) { animation-delay: 0.05s; }
.g-col-12:nth-child(2) .featured-card,
.featured-card:nth-child(2) { animation-delay: 0.12s; }
.g-col-12:nth-child(3) .featured-card,
.featured-card:nth-child(3) { animation-delay: 0.19s; }
.g-col-12:nth-child(4) .featured-card,
.featured-card:nth-child(4) { animation-delay: 0.26s; }


/* 14. Responsive ========================================================= */

@media screen and (max-width: 768px) {
    body:not(.quarto-sidebar-visible) .quarto-title-block {
        padding: 0.5rem 0 0;
    }
    body:not(.quarto-sidebar-visible) .quarto-title h1.title {
        font-size: 2rem;
    }
    .btn-primary,
    .btn-outline-primary {
        padding: 0.5rem 1.1rem;
        font-size: 0.875rem;
    }
    .featured-card {
        padding: 1.1rem 1.2rem 1.1rem 1.4rem;
    }
    .grid { gap: 0.75rem; }
}

@media screen and (max-width: 480px) {
    h1 { font-size: 1.6rem; }
    h2 { font-size: 1.25rem; }
}

/* ── Reduced-motion: respect user preference ─────────────────────── */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration:   0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration:  0.01ms !important;
    }
}
