/*--------------------------------------------------------------
# Premium skin + custom features, layered over the template CSS.
#
#  1. Design tokens (light & dark)
#  2. Global typography & polish
#  3. Sidebar
#  4. Hero
#  5. Section titles
#  6. About
#  7. Skills (chips + level badges)
#  8. Resume (timeline, buttons, modal)
#  9. Floating actions & utility buttons
# 10. Interactive terminal
# 11. Dark-theme component tweaks
--------------------------------------------------------------*/

/*--------------------------------------------------------------
# 1. Design tokens
--------------------------------------------------------------*/
:root {
    --bg: #FBFAF7;
    --bg-alt: #F4F0E7;
    --surface: #FFFFFF;
    --ink: #16242F;
    --text: #3D4B57;
    --muted: #75828D;
    --line: #E7E0D1;
    --gold: #C6A15B;
    --gold-strong: #A9853F;
    --gold-soft: rgba(198, 161, 91, 0.14);
    --navy: #0C1A2A;
    --navy-2: #11253B;
    --shadow-sm: 0 2px 10px rgba(18, 29, 40, 0.06);
    --shadow-md: 0 14px 34px rgba(18, 29, 40, 0.10);
}

html[data-theme="dark"] {
    --bg: #0B141E;
    --bg-alt: #0E1925;
    --surface: #13202E;
    --ink: #E9EEF3;
    --text: #C2CDD8;
    --muted: #8FA0B0;
    --line: #22344A;
    --gold: #D2AF6D;
    --gold-strong: #E0C285;
    --gold-soft: rgba(210, 175, 109, 0.12);
    --shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.35);
    --shadow-md: 0 14px 34px rgba(0, 0, 0, 0.45);
}

/*--------------------------------------------------------------
# 2. Global typography & polish
--------------------------------------------------------------*/
body {
    font-family: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
    background: var(--bg);
    color: var(--text);
    font-size: 16px;
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
    font-family: "Inter", system-ui, sans-serif;
    color: var(--ink);
}

a {
    color: var(--gold-strong);
    transition: color 0.25s;
}

    a:hover {
        color: var(--gold);
    }

::selection {
    background: var(--gold);
    color: #fff;
}

:focus-visible {
    outline: 2px solid var(--gold);
    outline-offset: 2px;
}

::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: rgba(127, 127, 127, 0.25);
    border-radius: 8px;
}

    ::-webkit-scrollbar-thumb:hover {
        background: rgba(127, 127, 127, 0.45);
    }

section {
    padding: 76px 0;
}

.section-bg {
    background: var(--bg-alt);
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        transition: none !important;
        animation: none !important;
    }
}

/*--------------------------------------------------------------
# 3. Sidebar
--------------------------------------------------------------*/
#header {
    background: linear-gradient(180deg, #0D1C2E 0%, #0A1521 100%);
    border-right: 1px solid rgba(255, 255, 255, 0.04);
}

    #header .profile img {
        width: 112px;
        border: 3px solid rgba(198, 161, 91, 0.55);
        box-shadow: 0 0 0 6px rgba(198, 161, 91, 0.12);
    }

    #header .profile h1 {
        font-family: "Playfair Display", Georgia, serif;
        font-size: 22px;
        font-weight: 600;
        letter-spacing: 0.02em;
    }

    #header .profile .social-links a {
        background: rgba(255, 255, 255, 0.06);
        border: 1px solid rgba(255, 255, 255, 0.08);
        color: #C8D2DC;
    }

        #header .profile .social-links a:hover {
            background: var(--gold);
            border-color: var(--gold);
            color: #0A1521;
        }

.nav-menu a,
.nav-menu a:focus {
    color: #8E9DAD;
    letter-spacing: 0.02em;
}

    .nav-menu a i,
    .nav-menu a:focus i {
        color: #5E6F80;
    }

    .nav-menu a:hover,
    .nav-menu .active,
    .nav-menu .active:focus,
    .nav-menu li:hover > a {
        color: #fff;
    }

        .nav-menu a:hover i,
        .nav-menu .active i,
        .nav-menu .active:focus i,
        .nav-menu li:hover > a i {
            color: var(--gold);
        }

#footer {
    background: #0A1521;
    color: #7E8C9A;
}

    #footer .copyright {
        font-size: 12px;
        letter-spacing: 0.08em;
    }

/*--------------------------------------------------------------
# 4. Hero
--------------------------------------------------------------*/
#hero:before {
    background: linear-gradient(180deg, rgba(7, 16, 27, 0.50) 0%, rgba(7, 16, 27, 0.62) 55%, rgba(7, 16, 27, 0.88) 100%);
}

/* The sidebar is 300px wide and fixed; offset the hero so its content
   centers within the visible area instead of the full viewport. */
@media (min-width: 1200px) {
    #hero {
        padding-left: 300px;
    }
}

#hero .hero-container {
    text-align: center;
    padding: 0 20px;
}

.hero-container::before {
    content: "";
    display: block;
    width: 64px;
    height: 2px;
    background: var(--gold);
    margin: 0 auto 28px;
}

#hero h1 {
    font-family: "Playfair Display", Georgia, serif;
    font-size: clamp(38px, 5.5vw, 76px);
    font-weight: 600;
    line-height: 1.08;
    letter-spacing: 0.01em;
    text-shadow: 0 2px 24px rgba(0, 0, 0, 0.35);
}

#hero p {
    font-family: "Inter", sans-serif;
    font-size: 15px;
    letter-spacing: 0.32em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.85);
    margin-top: 18px;
}

    /* Covers both the typed text and the typed.js cursor element,
       which the template otherwise underlines in blue. */
    #hero p span {
        color: var(--gold);
        border-bottom: 2px solid var(--gold);
        padding-bottom: 5px;
    }

    #hero p span.typed {
        letter-spacing: 0.32em;
    }

.hero-hint {
    font-size: 12px !important;
    letter-spacing: 0.18em !important;
    color: rgba(255, 255, 255, 0.5) !important;
    margin-top: -28px;
    text-transform: none !important;
}

    .hero-hint kbd {
        background: rgba(255, 255, 255, 0.10);
        border: 1px solid rgba(198, 161, 91, 0.65);
        border-radius: 4px;
        padding: 1px 7px;
        font-size: 12px;
        color: var(--gold);
    }

/*--------------------------------------------------------------
# 5. Section titles
--------------------------------------------------------------*/
.section-title {
    padding-bottom: 36px;
}

    .section-title .eyebrow {
        display: block;
        font-size: 12px;
        font-weight: 600;
        letter-spacing: 0.38em;
        text-transform: uppercase;
        color: var(--gold-strong);
        margin-bottom: 14px;
    }

    .section-title h2 {
        font-family: "Playfair Display", Georgia, serif;
        font-size: 42px;
        font-weight: 600;
        color: var(--ink);
    }

        .section-title h2::after {
            background: var(--gold);
            width: 64px;
            height: 2px;
        }

    .section-title p {
        max-width: 860px;
        font-size: 16.5px;
        line-height: 1.85;
        color: var(--text);
    }

/*--------------------------------------------------------------
# 6. About
--------------------------------------------------------------*/
.about img {
    border-radius: 16px;
    box-shadow: var(--shadow-md);
}

.about .content h3 {
    font-family: "Playfair Display", Georgia, serif;
    font-size: 27px;
    font-weight: 600;
    color: var(--ink);
}

.about .content .fst-italic {
    color: var(--muted);
}

.about .content ul i {
    color: var(--gold);
}

.about .content ul strong {
    color: var(--ink);
    font-weight: 600;
}

/*--------------------------------------------------------------
# 7. Skills
--------------------------------------------------------------*/
.skills .skills-content h4 {
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--muted);
}

    .skills .skills-content h4::before {
        content: "";
        display: inline-block;
        width: 18px;
        height: 1px;
        background: var(--gold);
        margin-right: 10px;
        vertical-align: middle;
    }

.skills .skill-item {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 10px 16px;
    box-shadow: var(--shadow-sm);
    color: var(--text);
    transition: transform 0.3s, box-shadow 0.3s, border-color 0.3s;
}

    .skills .skill-item:hover {
        transform: translateY(-3px);
        border-color: var(--gold);
        box-shadow: var(--shadow-md);
    }

/* Level badges: gold / silver / bronze */
.skill-level {
    font-size: 0.66rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    border-radius: 999px;
    padding: 3px 10px;
    line-height: 1.4;
    border: 1px solid transparent;
}

.skill-level-expert {
    background: var(--gold-soft);
    color: var(--gold-strong);
    border-color: rgba(198, 161, 91, 0.35);
}

.skill-level-proficient {
    background: rgba(141, 154, 166, 0.14);
    color: #667585;
    border-color: rgba(141, 154, 166, 0.30);
}

.skill-level-competent {
    background: rgba(160, 120, 74, 0.12);
    color: #97703F;
    border-color: rgba(160, 120, 74, 0.28);
}

/*--------------------------------------------------------------
# 8. Resume
--------------------------------------------------------------*/
.resume .resume-title {
    font-family: "Playfair Display", Georgia, serif;
    font-size: 25px;
    font-weight: 600;
    color: var(--ink);
}

.resume .resume-item {
    border-left: 1px solid var(--line);
    padding: 0 0 26px 26px;
}

    .resume .resume-item::before {
        width: 14px;
        height: 14px;
        left: -7.5px;
        background: var(--gold);
        border: 3px solid var(--bg);
        box-shadow: 0 0 0 1px var(--gold);
    }

    .resume .resume-item h4 {
        font-family: "Inter", sans-serif;
        font-size: 16.5px;
        font-weight: 600;
        letter-spacing: 0.01em;
        text-transform: none;
        line-height: 1.4;
        color: var(--ink);
    }

    .resume .resume-item h5 {
        font-size: 12px;
        font-weight: 600;
        letter-spacing: 0.14em;
        text-transform: uppercase;
        background: var(--gold-soft);
        color: var(--gold-strong);
        border-radius: 999px;
        padding: 5px 14px;
    }

    .resume .resume-item em {
        color: var(--muted);
    }

    .resume .resume-item ul li::marker {
        color: var(--gold);
    }

/* CV buttons */
.btn-cv {
    background: linear-gradient(135deg, #CDA967 0%, #AE8B3D 100%);
    color: #fff !important;
    border: none;
    border-radius: 999px;
    padding: 13px 30px;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    box-shadow: 0 12px 26px rgba(176, 141, 62, 0.28);
    transition: transform 0.3s, box-shadow 0.3s, background 0.3s;
}

    .btn-cv:hover,
    .btn-cv:focus {
        transform: translateY(-2px);
        box-shadow: 0 16px 32px rgba(176, 141, 62, 0.38);
        color: #fff;
    }

.btn-cv-outline {
    background: transparent;
    color: var(--ink) !important;
    border: 1px solid var(--gold);
    box-shadow: none;
}

    .btn-cv-outline:hover,
    .btn-cv-outline:focus {
        background: var(--gold-soft);
        box-shadow: none;
    }

.cv-note {
    font-size: 13px;
    font-style: italic;
    color: var(--muted);
}

    .cv-note i {
        color: var(--gold);
        font-style: normal;
    }

/* CV preview modal.
   The template's fixed sidebar uses z-index 9997, which is far above
   Bootstrap's modal layer (~1055) — lift the modal above the sidebar. */
.modal-backdrop {
    z-index: 10500;
}

.modal {
    z-index: 10501;
}

.modal-content {
    background: var(--surface);
    color: var(--text);
    border: none;
    border-radius: 16px;
    box-shadow: var(--shadow-md);
    overflow: hidden;
}

.modal-header {
    border-bottom: 1px solid var(--line);
}

.modal-title {
    font-family: "Playfair Display", Georgia, serif;
    color: var(--ink);
}

/*--------------------------------------------------------------
# 9. Floating actions & utility buttons
--------------------------------------------------------------*/
.floating-action,
.back-to-top {
    background: var(--navy-2);
    border: 1px solid rgba(198, 161, 91, 0.35);
    box-shadow: var(--shadow-sm);
}

.floating-action {
    position: fixed;
    right: 15px;
    z-index: 996;
    width: 40px;
    height: 40px;
    border-radius: 50px;
    color: var(--gold);
    font-size: 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.4s;
    cursor: pointer;
}

.back-to-top i {
    color: var(--gold);
}

.floating-action:hover,
.back-to-top:hover {
    background: var(--gold);
    border-color: var(--gold);
}

    .floating-action:hover,
    .floating-action:hover i,
    .back-to-top:hover i {
        color: #0A1521;
    }

#theme-toggle {
    bottom: 65px;
}

#terminal-toggle {
    bottom: 115px;
}

.mobile-nav-toggle {
    background-color: var(--navy-2);
    color: var(--gold);
    border: 1px solid rgba(198, 161, 91, 0.35);
}

/*--------------------------------------------------------------
# 10. Interactive terminal
--------------------------------------------------------------*/
.term-overlay {
    position: fixed;
    inset: 0;
    background: rgba(2, 8, 16, 0.6);
    backdrop-filter: blur(3px);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
}

    .term-overlay[hidden] {
        display: none;
    }

.term-window {
    width: min(760px, 92vw);
    height: min(500px, 82vh);
    background: #0C1118;
    border: 1px solid #243246;
    border-radius: 12px;
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.55);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    font-family: "Cascadia Code", Consolas, Menlo, "DejaVu Sans Mono", monospace;
}

.term-bar {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 10px 14px;
    background: #161D27;
    flex: 0 0 auto;
}

.term-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    display: inline-block;
}

.term-title {
    color: #8B98A9;
    font-size: 12px;
    margin-left: 8px;
}

.term-body {
    flex: 1 1 auto;
    overflow-y: auto;
    padding: 14px 16px 6px;
    font-size: 13.5px;
    line-height: 1.55;
    color: #D6E2F0;
}

.term-line {
    white-space: pre-wrap;
    word-break: break-word;
    min-height: 1.2em;
}

    .term-line a {
        color: #4FC3F7;
        text-decoration: underline;
    }

.term-prompt-label {
    color: #5BE38B;
    white-space: nowrap;
}

.term-input-row {
    display: flex;
    align-items: center;
    padding: 6px 16px 14px;
    flex: 0 0 auto;
    font-size: 13.5px;
}

.term-input {
    flex: 1;
    margin-left: 8px;
    background: transparent;
    border: none;
    outline: none;
    color: #D6E2F0;
    caret-color: #5BE38B;
    font: inherit;
}

.term-muted {
    color: #7D8B9D;
}

.term-accent {
    color: #4FC3F7;
}

.term-warn {
    color: #FFB86B;
}

.term-ok {
    color: #5BE38B;
}

body.term-open {
    overflow: hidden;
}

/*--------------------------------------------------------------
# 11. Dark-theme component tweaks
#     (everything else follows the tokens automatically)
--------------------------------------------------------------*/
html[data-theme="dark"] .btn-close {
    filter: invert(1) grayscale(100%) brightness(200%);
}

html[data-theme="dark"] .skill-level-proficient {
    color: #9FB0C0;
}

html[data-theme="dark"] .skill-level-competent {
    color: #C09A6A;
}

html[data-theme="dark"] #header {
    border-right-color: rgba(255, 255, 255, 0.06);
}
