/* ========== Reset ========== */

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

body {
    background: #fff;
    font-family: system-ui, -apple-system, sans-serif;
}

/* ========== Page Layout ========== */

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

/* Header */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: var(--mac-case-body);
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.header-nav {
    padding: 1rem 2rem;
    display: flex;
    align-items: center;
}

.header-home {
    flex: 0 0 220px;
    padding-left: 1.5rem;
    box-sizing: border-box;
    color: #000;
    text-decoration: none;
    font-size: 1rem;
    font-weight: 400;
    letter-spacing: 0.05em;
    transition: color 0.2s;
}

.header-home:hover {
    color: #333;
}

.header-page-link {
    color: #000;
    text-decoration: none;
    font-size: 1rem;
    font-weight: 400;
    letter-spacing: 0.05em;
    margin-left: 1.5rem;
    transition: color 0.2s;
}

.header-page-link:hover {
    color: #333;
}

.header-home::selection {
    background: rgba(255, 255, 255, 0.3);
    color: #fff;
}

/* Page body: sidebar + main content */
.page-body {
    flex: 1;
    display: flex;
}

/* Sidebar */
.sidebar {
    position: sticky;
    top: 0;
    align-self: flex-start;
    width: 220px;
    min-width: 220px;
    height: 100vh;
    padding: 2rem 1.5rem;
    background: var(--mac-case-body);
    border-right: 1px solid rgba(0, 0, 0, 0.1);
    overflow-y: auto;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.sidebar-label {
    font-size: 1.1rem;
    font-weight: 300;
    letter-spacing: 0.03em;
    text-decoration: underline;
    color: #000;
    margin-top: 1rem;
}

.sidebar-nav a {
    display: block;
    padding: 0.55rem 0.85rem;
    background: #fff;
    border: 1px solid rgba(0, 0, 0, 0.15);
    border-radius: 3px;
    color: #000;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 300;
    letter-spacing: 0.03em;
    transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease, transform 0.1s ease;
}

.sidebar-nav a:hover {
    background: var(--apple-platinum);
    border-color: var(--apple-platinum-shadow);
    color: #000;
}

.sidebar-nav a:active {
    background: var(--apple2-grey2);
    border-color: var(--apple2-case-legends);
    color: #000;
    transform: translateY(1px);
}

.sidebar-nav a.active {
    background: var(--apple2-grey2);
    border-color: var(--apple2-case-legends);
    color: #000;
    font-weight: 600;
}

.sidebar-nav a.active:hover {
    background: var(--apple2-grey2);
    border-color: var(--apple2-case-legends);
    color: #000;
}

/* Main content */
.main-content {
    flex: 1;
    padding: 3rem 4rem;
    overflow-y: auto;
    background: #fff;
}

.main-content h1 {
    font-size: 2.5rem;
    font-weight: 300;
    margin-bottom: 2rem;
}

.main-content h2 {
    font-size: 1.5rem;
    font-weight: 400;
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.main-content p {
    font-weight: 300;
    line-height: 1.7;
    margin-bottom: 1.5rem;
}

.main-content section {
    margin-bottom: 2rem;
}

.main-content ul {
    padding-left: 1.5rem;
    margin-bottom: 1rem;
}

.main-content li {
    font-weight: 300;
    line-height: 1.7;
}

/* ========== Theme: header ========== */

.theme-professional .site-header {
    background: #1a2744;
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

.theme-professional .header-home {
    color: #fff;
}

.theme-professional .header-home:hover {
    color: #000;
}

.theme-professional .header-page-link {
    color: #fff;
}

.theme-professional .header-page-link:hover {
    color: #aac;
}

.theme-software .site-header {
    background: #505050;
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

.theme-software .header-home {
    color: #fff;
}

.theme-software .header-home:hover {
    color: #ccc;
}

.theme-software .header-page-link {
    color: #fff;
}

.theme-software .header-page-link:hover {
    color: #ccc;
}

.theme-personal .site-header {
    background: #5b9bd5;
    border-bottom-color: rgba(0, 0, 0, 0.1);
}

.theme-personal .header-home {
    color: #fff;
}

.theme-personal .header-home:hover {
    color: #000;
}

.theme-personal .header-page-link {
    color: #fff;
}

.theme-personal .header-page-link:hover {
    color: #1a2744;
}


/* ========== Theme: sidebar ========== */

.theme-professional .sidebar {
    background: #1a2744;
    border-right-color: rgba(255, 255, 255, 0.1);
}

.theme-professional .sidebar-label {
    color: #fff;
}

.theme-professional .sidebar-nav a {
    background: var(--theme-professional-bg);
    border: 1px solid rgba(0, 0, 0, 0.15);
    color: var(--theme-professional-text);
}

.theme-professional .sidebar-nav a:hover {
    background: var(--apple-platinum);
    border-color: var(--apple-platinum-shadow);
    color: #000;
}

.theme-professional .sidebar-nav a:active {
    background: var(--apple2-grey2);
    border-color: var(--apple2-case-legends);
    color: #000;
}

.theme-professional .sidebar-nav a.active {
    background: var(--apple2-grey2);
    border-color: var(--apple2-case-legends);
    color: #000;
}

.theme-professional .sidebar-nav a.active:hover {
    background: var(--apple2-grey2);
    border-color: var(--apple2-case-legends);
    color: #000;
}

.theme-software .sidebar {
    background: #505050;
    border-right-color: rgba(255, 255, 255, 0.1);
}

.theme-software .sidebar-label {
    color: #fff;
}

.theme-software .sidebar-nav a {
    background: var(--theme-software-bg);
    border: 1px solid rgba(0, 0, 0, 0.15);
    color: var(--theme-software-text);
}

.theme-software .sidebar-nav a:hover {
    background: var(--apple-platinum);
    border-color: var(--apple-platinum-shadow);
    color: #000;
}

.theme-software .sidebar-nav a:active {
    background: var(--apple2-grey2);
    border-color: var(--apple2-case-legends);
    color: #000;
}

.theme-software .sidebar-nav a.active {
    background: var(--apple2-grey2);
    border-color: var(--apple2-case-legends);
    color: #000;
}

.theme-software .sidebar-nav a.active:hover {
    background: var(--apple2-grey2);
    border-color: var(--apple2-case-legends);
    color: #000;
}

.theme-personal .sidebar {
    background: #5b9bd5;
    border-right-color: rgba(0, 0, 0, 0.1);
}

.theme-personal .sidebar-label {
    color: #fff;
}

.theme-personal .sidebar-nav a {
    background: var(--theme-personal-bg);
    border: 1px solid rgba(0, 0, 0, 0.15);
    color: var(--theme-personal-text);
}

.theme-personal .sidebar-nav a:hover {
    background: var(--apple-platinum);
    border-color: var(--apple-platinum-shadow);
    color: #000;
}

.theme-personal .sidebar-nav a:active {
    background: var(--apple2-grey2);
    border-color: var(--apple2-case-legends);
    color: #000;
}

.theme-personal .sidebar-nav a.active {
    background: lightblue;
    border-color: var(--apple2-case-legends);
    color: #000;
}

.theme-personal .sidebar-nav a.active:hover {
    background: lightblue;
    border-color: var(--apple2-case-legends);
    color: #000;
}

/* ========== Footer ========== */

.site-footer {
    background: var(--mac-case-body);
    color: #000;
    padding: 3rem 2rem;
    font-size: 0.9rem;
    font-weight: 300;
}

.footer-content {
    max-width: 900px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    text-align: center;
}

.footer-socials {
    display: flex;
    gap: 2rem;
}

.footer-socials a {
    color: #000;
    text-decoration: none;
    letter-spacing: 0.05em;
    transition: color 0.2s;
}

.footer-socials a:hover {
    color: #333;
}

.footer-contact a {
    color: #000;
    text-decoration: none;
    transition: color 0.2s;
}

.footer-contact a:hover {
    color: #333;
}

.footer-copyright {
    color: #000;
    font-size: 0.8rem;
}

.footer-links a {
    color: #000;
    text-decoration: none;
    font-size: 0.8rem;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: #333;
}

.theme-professional .site-footer {
    background: #1a2744;
    color: #fff;
}

.theme-professional .footer-socials a,
.theme-professional .footer-contact a,
.theme-professional .footer-copyright {
    color: #fff;
}

.theme-professional .footer-socials a:hover,
.theme-professional .footer-contact a:hover {
    color: #aac;
}

.theme-professional .footer-links a {
    color: #fff;
}

.theme-professional .footer-links a:hover {
    color: #aac;
}

.theme-software .site-footer {
    background: #505050;
    color: #fff;
}

.theme-software .footer-socials a,
.theme-software .footer-contact a,
.theme-software .footer-copyright {
    color: #fff;
}

.theme-software .footer-socials a:hover,
.theme-software .footer-contact a:hover {
    color: #ccc;
}

.theme-software .footer-links a {
    color: #fff;
}

.theme-software .footer-links a:hover {
    color: #ccc;
}

.theme-personal .site-footer {
    background: #5b9bd5;
    color: #fff;
}

.theme-personal .footer-socials a,
.theme-personal .footer-contact a,
.theme-personal .footer-copyright {
    color: #fff;
}

.theme-personal .footer-socials a:hover,
.theme-personal .footer-contact a:hover {
    color: #1a2744;
}

.theme-personal .footer-links a {
    color: #fff;
}

.theme-personal .footer-links a:hover {
    color: #1a2744;
}

/* ========== Components: captcha & cookie banner ========== */

.captcha-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.65);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.captcha-overlay.visible {
    display: flex;
}

.captcha-box {
    background: var(--apple-platinum);
    border-bottom: 3px solid var(--apple-platinum-shadow);
    padding: 2.5rem 3rem;
    text-align: center;
    max-width: 420px;
    width: 90%;
}

.captcha-box h2 {
    font-size: 2rem;
    font-weight: 300;
    color: var(--apple-platinum-legends);
    letter-spacing: -0.01em;
    margin-bottom: 0.4rem;
}

.captcha-box p {
    font-size: 0.9rem;
    font-weight: 300;
    color: rgba(44, 44, 44, 0.55);
    letter-spacing: 0.03em;
    margin-bottom: 1.5rem;
}

.captcha-widget {
    display: flex;
    justify-content: center;
}

.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--apple-platinum);
    border-top: 2px solid var(--apple-platinum-shadow);
    color: var(--apple-platinum-legends);
    padding: 1rem 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    z-index: 999;
    font-size: 0.85rem;
    font-weight: 300;
    letter-spacing: 0.02em;
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.cookie-banner.visible {
    transform: translateY(0);
}

.cookie-banner p {
    flex: 1;
    line-height: 1.5;
}

.cookie-buttons {
    display: flex;
    gap: 0.75rem;
    flex-shrink: 0;
}

.cookie-btn {
    padding: 0.4rem 1.2rem;
    border: 1px solid rgba(44, 44, 44, 0.25);
    background: transparent;
    color: var(--apple-platinum-legends);
    font-size: 0.85rem;
    font-weight: 300;
    font-family: inherit;
    letter-spacing: 0.05em;
    cursor: pointer;
    transition: background 0.2s;
    text-decoration: none;
    display: inline-block;
}

.cookie-btn:hover {
    background: rgba(44, 44, 44, 0.08);
}

/* ========== Professional Portfolio Downloads ========== */
.doc-list {
    list-style: none;
    margin: 1.5rem 0 0;
    padding: 0;
    max-width: 640px;
}

.doc-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.9rem 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.12);
}

.doc-name {
    font-size: 0.95rem;
    font-weight: 300;
}

.doc-actions {
    display: flex;
    gap: 0.6rem;
    flex-shrink: 0;
}

.doc-btn {
    padding: 0.45rem 1.1rem;
    border: 1px solid rgba(0, 0, 0, 0.4);
    background: transparent;
    color: #000;
    font-family: inherit;
    font-size: 0.85rem;
    font-weight: 300;
    letter-spacing: 0.03em;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.2s;
}

.doc-btn:hover {
    background: rgba(0, 0, 0, 0.08);
}
