:root {
    --bg: #1a1720;
    --bg-gradient: linear-gradient(145deg, #1a1720 0%, #1e1828 50%, #1a1720 100%);
    --surface: #24202c;
    --surface-hover: #2e2938;
    --border: #342e3e;
    --accent: #e07a94;
    --accent-hover: #ea8da3;
    --accent-gradient: linear-gradient(135deg, #e07a94, #c86b83);
    --accent-glow: rgba(224, 122, 148, 0.15);
    --text: #ede9e5;
    --text-secondary: #b5b0ab;
    --text-muted: #7d7975;
    --shadow-sm: 0 1px 4px rgba(0, 0, 0, 0.2);
    --shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.3);
    --font-heading: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-body: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

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

body {
    font-family: var(--font-body);
    background: var(--bg);
    background-image: var(--bg-gradient);
    background-attachment: fixed;
    color: var(--text);
    min-height: 100vh;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
}

header {
    padding: 16px 20px;
    background: rgba(36, 32, 44, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

header h1 {
    font-size: 18px;
    font-weight: 600;
    color: var(--accent);
    letter-spacing: -0.01em;
}

.header-logo {
    height: 52px;
    width: 52px;
    object-fit: contain;
    vertical-align: middle;
    margin-right: 6px;
    border-radius: 4px;
}

.header-link,
#logout-link,
#login-link {
    position: absolute;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 13px;
    font-family: var(--font-heading);
    font-weight: 500;
    transition: color 0.2s;
}

.header-link:hover,
#logout-link:hover,
#login-link:hover {
    color: var(--accent);
}

.header-link.left { left: 20px; }
.header-link.right,
#logout-link,
#login-link { right: 20px; }

footer {
    padding: 24px;
    text-align: center;
    font-size: 13px;
    display: flex;
    gap: 16px;
    justify-content: center;
}

footer a {
    color: var(--text-muted);
    text-decoration: none;
    transition: color 0.2s;
}

footer a:hover {
    color: var(--accent);
}

.header-right-links {
    position: absolute;
    right: 20px;
    display: flex;
    gap: 16px;
    align-items: center;
}

.header-right-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 13px;
    font-family: var(--font-heading);
    font-weight: 500;
    transition: color 0.2s;
}

.header-right-links a:hover {
    color: var(--accent);
}

/* Modal */

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 200;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal-content {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 32px;
    max-width: 400px;
    width: 100%;
    text-align: center;
    box-shadow: var(--shadow-lg);
}

.modal-content h2 {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 12px;
    letter-spacing: -0.02em;
}

.modal-content p {
    font-size: 15px;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 24px;
}

.modal-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.modal-btn {
    padding: 12px 24px;
    border-radius: 10px;
    font-family: var(--font-heading);
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    transition: opacity 0.2s, transform 0.1s;
    border: none;
}

.modal-btn.primary {
    background: var(--accent-gradient);
    color: #fff;
    box-shadow: var(--shadow-sm);
}

.modal-btn.primary:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

.modal-btn.secondary {
    background: transparent;
    color: var(--text-muted);
    font-size: 14px;
}

.modal-btn.secondary:hover {
    color: var(--text-secondary);
}

/* Hamburger menu — mobile only */

.hamburger {
    display: none;
    position: absolute;
    right: 16px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    z-index: 11;
    flex-direction: column;
    gap: 5px;
}

.hamburger span {
    display: block;
    width: 20px;
    height: 2px;
    background: var(--text-secondary);
    border-radius: 1px;
    transition: transform 0.2s, opacity 0.2s;
}

.hamburger.open span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.hamburger.open span:nth-child(2) {
    opacity: 0;
}

.hamburger.open span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

.hamburger-menu {
    display: none;
    position: absolute;
    top: 100%;
    right: 12px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
    z-index: 10;
    min-width: 160px;
    overflow: hidden;
}

.hamburger-menu a {
    display: block;
    padding: 12px 20px;
    color: var(--text);
    text-decoration: none;
    font-family: var(--font-heading);
    font-size: 14px;
    font-weight: 500;
    transition: background 0.15s;
}

.hamburger-menu a:hover {
    background: var(--surface-hover);
}

.hamburger-menu a:not(:last-child) {
    border-bottom: 1px solid var(--border);
}

.hidden {
    display: none !important;
}

@media (max-width: 600px) {
    header { padding: 12px 16px; }
    header .header-logo { display: none; }
    .header-link.left,
    .header-link.right,
    .header-right-links,
    #logout-link { display: none; }
    .hamburger { display: flex; }
    .hamburger-menu:not(.hidden) { display: block; }
    .modal-content { padding: 24px; }
}
