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

:root, [data-theme="light"] {
    --blue:              rgb(0, 123, 255);
    --blue-dark:         rgb(0, 98, 203);
    --blue-tint:         rgba(0, 123, 255, 0.07);
    --border:            #e2e6ea;
    --border-dot:        rgb(212, 212, 212);
    --text:              #1a1a1a;
    --muted:             #6c757d;
    --bg:                #ffffff;
    --surface:           #f8f9fa;
    --nav-bg:            rgba(255, 255, 255, 0.85);
    --card-hover-border: #d0dce8;
    --card-hover-shadow: rgba(0, 0, 0, 0.04);
    --p-color:           #444;
}

[data-theme="dark"] {
    --border:            #2a2d35;
    --border-dot:        #3a3d47;
    --text:              #e8ecf3;
    --muted:             #6b7585;
    --bg:                #0d0f12;
    --surface:           #13161b;
    --nav-bg:            rgba(13, 15, 18, 0.85);
    --card-hover-border: #252830;
    --card-hover-shadow: rgba(0, 0, 0, 0.15);
    --p-color:           #bcc5d2;
}

html { height: 100%; }

body {
    min-height: 100vh;
    background: var(--bg);
    color: var(--text);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    font-size: 15px;
    line-height: 1.7;
    transition: background 0.25s, color 0.25s;
}

/* ── Navbar ── */
.navbar {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 100;
    height: 52px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    background: var(--nav-bg);
    border-bottom: 1px solid var(--border);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    transition: background 0.25s, border-color 0.25s;
}

.nav-links { display: flex; gap: 4px; }

.nav-link {
    padding: 5px 14px;
    border-radius: 6px;
    color: var(--muted);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    transition: color 0.15s, background 0.15s;
}

.nav-link:hover  { color: var(--text); background: var(--border); }
.nav-link.active { color: var(--blue); background: var(--blue-tint); }

.theme-toggle {
    width: 34px; height: 34px;
    border-radius: 8px;
    border: 1px solid var(--border);
    background: transparent;
    color: var(--muted);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    transition: border-color 0.15s, color 0.15s, background 0.15s;
}

.theme-toggle:hover {
    border-color: var(--blue);
    color: var(--blue);
    background: var(--blue-tint);
}

/* ── Layout ── */
.layout {
    display: flex;
    min-height: 100vh;
    padding-top: 52px;
}

/* ── Left panel ── */
.panel-left {
    width: 320px;
    position: sticky;
    top: 52px;
    height: calc(100vh - 52px);
    background: var(--surface);
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    flex-shrink: 0;
    animation: slideLeft 0.55s cubic-bezier(.22,.68,0,1.2) both;
    transition: background 0.25s, border-color 0.25s;
}

.panel-right {
    flex: 1;
    padding: 48px 52px;
    overflow-y: auto;
}

.panel-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    flex: 1;
    gap: 18px;
    padding: 36px 28px;
    text-align: center;
}

/* ── Profile picture ── */
.pfp-wrap { position: relative; width: 148px; height: 148px; }

.pfp-ring {
    position: absolute;
    inset: -4px;
    border-radius: 50%;
    background: conic-gradient(var(--blue), var(--blue-dark), var(--blue));
    animation: spin 7s linear infinite;
}

.pfp-wrap::before {
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: 50%;
    background: var(--surface);
    z-index: 1;
    transition: background 0.25s;
}

#pfp {
    position: absolute;
    inset: 0;
    width: 100%; height: 100%;
    border-radius: 50%;
    object-fit: cover;
    z-index: 2;
}

/* ── Name ── */
h1 {
    font-size: 1.55rem;
    line-height: 1.2;
    font-weight: 600;
    border-bottom: 3px dotted var(--border-dot);
    padding-bottom: 14px;
    transition: border-color 0.25s;
    cursor: default;
}

.tagline {
    font-family: ui-monospace, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
    font-size: 0.7rem;
    color: var(--muted);
    letter-spacing: 0.07em;
    text-transform: uppercase;
    margin-top: -6px;
}

/* ── Social links ── */
.social-links { display: flex; flex-direction: column; gap: 7px; width: 100%; }

.social-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 15px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--bg);
    color: var(--muted);
    text-decoration: none;
    font-size: 0.85rem;
    transition: border-color 0.18s, color 0.18s, background 0.18s;
}

.social-btn:hover { border-color: var(--blue); color: var(--blue); background: var(--blue-tint); }
.social-btn i { font-size: 1rem; flex-shrink: 0; }

/* ── Resume button ── */
.resume-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 22px;
    border-radius: 8px;
    border: 2px solid var(--blue);
    background: var(--blue);
    color: #fff;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    transition: background 0.18s, border-color 0.18s, transform 0.1s;
}

.resume-btn:hover  { background: var(--blue-dark); border-color: var(--blue-dark); color: #fff; }
.resume-btn:active { transform: translateY(2px); }

/* ── Copyright ── */
.copyright {
    font-family: ui-monospace, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
    font-size: 0.65rem;
    color: var(--muted);
    letter-spacing: 0.05em;
    padding-bottom: 20px;
    opacity: 0.6;
}

/* ── Shared interactive ── */
a {
    color: var(--blue);
    text-decoration: none;
    transition: color 0.15s;
}

a:hover { color: var(--blue-dark); }

.chevron-btn {
    width: 28px; height: 28px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    border: 1px solid var(--border);
    background: none;
    color: var(--muted);
    cursor: pointer;
    transition: border-color 0.15s, color 0.15s, background 0.15s;
}

.chevron-btn:hover {
    border-color: var(--blue);
    color: var(--blue);
    background: var(--blue-tint);
}

.chevron-btn:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }

.toggle-icon {
    font-size: 0.8rem;
    transition: transform 0.25s cubic-bezier(.22,.68,0,1.2);
}

.chevron-btn[aria-expanded="false"] .toggle-icon { transform: rotate(-90deg); }

/* ── Pills ── */
.pill {
    font-family: ui-monospace, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
    font-size: 0.68rem;
    letter-spacing: 0.04em;
    padding: 3px 10px;
    border-radius: 999px;
    border: 1px solid var(--border);
    color: var(--muted);
    background: var(--bg);
    cursor: default;
}

/* ── Animations ── */
@keyframes slideLeft {
    from { opacity: 0; transform: translateX(-20px); }
    to   { opacity: 1; transform: translateX(0); }
}

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

@keyframes spin { to { transform: rotate(360deg); } }

/* ── Responsive ── */
@media (max-width: 700px) {
    .layout { flex-direction: column; }
    .panel-left {
        width: 100%; height: auto;
        position: static;
        border-right: none;
        border-bottom: 1px solid var(--border);
    }
    .panel-right { padding: 28px 18px; }
}
