/* Olio Profile Page - Clean Minimal Design */
@font-face {
    font-family: 'Outfit';
    src: url('../fonts/outfit/outfit-variable.ttf') format("truetype-variations");
    font-weight: 1 999;
}

/* ===========================
   CSS Variables & Themes
   =========================== */
:root {
    --primary: #0D3E50;
    --accent: #2BD500;
    --accent-hover: #25b800;
    --text: #0D3E50;
    --text-light: #5a7a8a;
    --background: #ffffff;
    --link-bg: #ffffff;
    --link-border: #e2e8ed;
    --avatar-bg: #0D3E50;
    --avatar-border: rgba(13, 62, 80, 0.15);
}

.theme-light {
    --background: #ffffff;
    --text: #0D3E50;
    --text-light: #5a7a8a;
    --link-bg: #ffffff;
    --link-border: #e2e8ed;
    --avatar-bg: #0D3E50;
    --avatar-border: rgba(13, 62, 80, 0.15);
}

.theme-dark {
    --background: #0D3E50;
    --text: #ffffff;
    --text-light: #a8c4d0;
    --link-bg: #164a5e;
    --link-border: #1d5a70;
    --avatar-bg: #2BD500;
    --avatar-border: rgba(43, 213, 0, 0.3);
}

.theme-midnight {
    --background: #0d1117;
    --text: #c9d1d9;
    --text-light: #8b949e;
    --link-bg: #161b22;
    --link-border: #30363d;
    --avatar-bg: #58a6ff;
    --avatar-border: rgba(88, 166, 255, 0.3);
}

.theme-ocean {
    --background: #f0f9ff;
    --text: #0c4a6e;
    --text-light: #0369a1;
    --link-bg: #ffffff;
    --link-border: #bae6fd;
    --avatar-bg: #0ea5e9;
    --avatar-border: rgba(14, 165, 233, 0.2);
}

.theme-forest {
    --background: #f0fdf4;
    --text: #14532d;
    --text-light: #166534;
    --link-bg: #ffffff;
    --link-border: #bbf7d0;
    --avatar-bg: #22c55e;
    --avatar-border: rgba(34, 197, 94, 0.2);
}

.theme-sunset {
    --background: #fffbeb;
    --text: #78350f;
    --text-light: #92400e;
    --link-bg: #ffffff;
    --link-border: #fde68a;
    --avatar-bg: #f59e0b;
    --avatar-border: rgba(245, 158, 11, 0.2);
}

.theme-purple {
    --background: #faf5ff;
    --text: #581c87;
    --text-light: #7e22ce;
    --link-bg: #ffffff;
    --link-border: #e9d5ff;
    --avatar-bg: #a855f7;
    --avatar-border: rgba(168, 85, 247, 0.2);
}

.theme-gray {
    --background: #f9fafb;
    --text: #1f2937;
    --text-light: #6b7280;
    --link-bg: #ffffff;
    --link-border: #e5e7eb;
    --avatar-bg: #6b7280;
    --avatar-border: rgba(107, 114, 128, 0.2);
}

.theme-red {
    --background: #fef2f2;
    --text: #7f1d1d;
    --text-light: #991b1b;
    --link-bg: #ffffff;
    --link-border: #fecaca;
    --avatar-bg: #ef4444;
    --avatar-border: rgba(239, 68, 68, 0.2);
}

/* ===========================
   Base Styles
   =========================== */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
}

body {
    font-family: 'Outfit', -apple-system, sans-serif;
    background: var(--background);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    padding: 48px 20px 32px;
}

/* ===========================
   Profile Container
   =========================== */
.profile-container {
    width: 100%;
    max-width: 440px;
}

.profile-box {
    display: flex;
    flex-direction: column;
}

/* ===========================
   Profile Header
   =========================== */
.profile-header {
    text-align: center;
    margin-bottom: 36px;
}

/* Avatar */
.avatar {
    width: 96px;
    height: 96px;
    border-radius: 50%;
    margin: 0 auto 18px;
    border: 4px solid var(--avatar-border);
    overflow: hidden;
}

.avatar.has-image {
    background: var(--link-bg);
}

.avatar.has-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.avatar.no-avatar {
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--avatar-bg);
    color: #ffffff;
    font-size: 40px;
    font-weight: 600;
    line-height: 1;
}

/* Name */
.profile-header h1 {
    font-size: 1.625rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 6px;
    letter-spacing: -0.01em;
}

/* Blurb */
.blurb {
    font-size: 15px;
    color: var(--text-light);
    line-height: 1.5;
}

/* ===========================
   Links
   =========================== */
.category-heading {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-light);
    margin: 28px 0 14px;
    opacity: 0.7;
}

.link-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.link-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    background: var(--link-bg);
    border: 1px solid var(--link-border);
    border-radius: 10px;
    transition: all 0.15s ease;
}

.link-item:hover {
    border-color: var(--accent);
    transform: translateX(4px);
}

.link-favicon {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    object-fit: contain;
    filter: grayscale(100%);
    opacity: 0.6;
    transition: all 0.2s ease;
}

.link-item:hover .link-favicon {
    filter: grayscale(0%);
    opacity: 1;
}

.link-favicon.fa-link {
    font-size: 14px;
    color: var(--text-light);
    width: 20px;
    text-align: center;
}

.link-icon {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.link-icon i {
    line-height: 1;
    color: var(--text-light, #666);
    transition: color 0.2s ease;
}

.link-item:hover .link-icon i {
    color: var(--accent, #2ecc71);
}

.link-item a {
    flex: 1;
    font-size: 15px;
    font-weight: 500;
    color: var(--text);
    text-decoration: none;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.link-item:hover a {
    color: var(--accent);
}

/* ===========================
   Contact Section
   =========================== */
.contact-section {
    margin-top: 32px;
    text-align: center;
}

.contact-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: var(--link-bg);
    color: var(--text-light);
    font-size: 14px;
    font-weight: 500;
    font-family: inherit;
    border: 1px solid var(--link-border);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.15s ease;
}

.contact-btn i {
    font-size: 13px;
}

.contact-btn:hover {
    border-color: var(--accent);
    color: var(--accent);
}

/* ===========================
   Branding
   =========================== */
.branding {
    text-align: center;
    font-size: 11px;
    color: var(--text-light);
    margin-top: 48px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    opacity: 0.5;
}

.branding a {
    display: inline-flex;
}

.branding img {
    height: 16px;
}

.branding:hover {
    opacity: 0.8;
}

/* ===========================
   Not Found
   =========================== */
.not-found {
    text-align: center;
    padding: 60px 20px;
}

.oops-logo {
    height: 28px;
    margin-bottom: 20px;
    opacity: 0.8;
}

.not-found .note {
    font-size: 15px;
    color: var(--text-light);
    max-width: 300px;
    margin: 0 auto;
}

.not-found a {
    color: var(--accent);
    font-weight: 600;
}

/* ===========================
   Contact Modal
   =========================== */
.contact-modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.contact-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.contact-modal-content {
    position: relative;
    width: 100%;
    max-width: 400px;
    background: var(--link-bg);
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
    animation: modalFade 0.2s ease;
}

@keyframes modalFade {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

.contact-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 22px;
    border-bottom: 1px solid var(--link-border);
}

.contact-modal-title {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--text);
}

.contact-modal-close {
    background: none;
    border: none;
    font-size: 24px;
    color: var(--text-light);
    cursor: pointer;
    line-height: 1;
    padding: 4px;
}

.contact-modal-close:hover {
    color: var(--text);
}

.contact-modal-body {
    padding: 22px;
}

/* Contact Form */
.contact-form .form-group {
    margin-bottom: 16px;
}

.contact-form label {
    display: block;
    margin-bottom: 6px;
    font-size: 13px;
    font-weight: 600;
    color: var(--text);
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 11px 14px;
    background: var(--background);
    border: 1px solid var(--link-border);
    border-radius: 8px;
    font-size: 15px;
    font-family: inherit;
    color: var(--text);
    transition: border-color 0.15s;
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--accent);
}

.contact-form textarea {
    resize: vertical;
    min-height: 100px;
}

.contact-submit-btn {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 20px;
    background: var(--accent);
    color: white;
    font-size: 14px;
    font-weight: 600;
    font-family: inherit;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.15s;
}

.contact-submit-btn:hover {
    background: var(--accent-hover);
}

.contact-submit-btn:disabled {
    cursor: not-allowed;
    opacity: 0.7;
}

.contact-submit-btn:disabled:hover {
    background: var(--accent);
}

/* Contact Alerts */
.contact-alert {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 14px;
    border-radius: 8px;
    margin-bottom: 16px;
    font-size: 14px;
}

.contact-alert-success {
    background: #d1fae5;
    color: #065f46;
}

.contact-alert-error {
    background: #fee2e2;
    color: #991b1b;
}

/* ===========================
   Responsive
   =========================== */
@media (max-width: 480px) {
    body {
        padding: 32px 16px 24px;
    }
    
    .avatar {
        width: 84px;
        height: 84px;
    }
    
    .avatar.no-avatar {
        font-size: 36px;
    }
    
    .profile-header h1 {
        font-size: 1.5rem;
    }
    
    .link-item {
        padding: 12px 14px;
    }
}
