/* Modern Layout Overrides & System - HIGH DENSITY MODE */
:root {
    --color-text: #00323E;
    --color-text-light: #4A6E76;

    /* Transparent backgrounds */
    --color-bg-card: rgba(255, 255, 255, 0.6);
    --color-bg-card-hover: rgba(255, 255, 255, 0.85);

    --color-border: rgba(0, 50, 62, 0.1);

    /* Tighter spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 1.5rem;
    --spacing-lg: 2.5rem;

    --radius-sm: 8px;
    --radius-md: 12px;

    --shadow-sm: 0 1px 3px rgba(0, 50, 62, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 50, 62, 0.1);

    --font-stack-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    --font-size-sm: 0.9rem;
    --font-size-base: 1rem;
}

html,
body {
    height: auto;
    min-height: 100%;
    overflow-y: auto;
    display: block;
}

body {
    font-family: var(--font-stack-body);
    color: var(--color-text);
    line-height: 1.5;
    padding: 0;
    margin: 0;
}

/* Layout Utilities */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-sm);
}

/* 2-Column Dashboard Layout */
.dashboard-grid {
    display: grid;
    grid-template-columns: 1fr 340px;
    /* Main content + Sidebar */
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-lg);
    align-items: start;
}

@media (max-width: 850px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
}

/* Compact Header */
.site-header {
    padding: var(--spacing-sm) 0;
    margin-bottom: var(--spacing-md);
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--color-border);
    backdrop-filter: blur(5px);
}

.brand {
    font-family: 'Damion', cursive;
    font-size: 1.5rem;
    color: var(--color-text);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.brand:hover {
    text-decoration: none;
    /* No underline on hover for brand */
}

.brand span {
    font-size: 1.8rem;
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    /* Bouncy transition */
    display: inline-block;
}

.brand:hover span {
    transform: scale(1.3) rotate(5deg);
    /* Scale up and slight tilt on hover */
}

/* Typography overrides for density */
h1,
h2,
h3,
h4 {
    margin: 0 0.25rem 0.25rem 0;
}

p {
    margin: 0 0 var(--spacing-sm) 0;
}

.section-title {
    font-size: 1.1rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-text-light);
    border-bottom: 2px solid var(--color-border);
    padding-bottom: 0.25rem;
    margin-bottom: var(--spacing-sm);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.card {
    background: var(--color-bg-card);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: var(--spacing-md);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    border: 1px solid rgba(255, 255, 255, 0.3);
    margin-bottom: var(--spacing-md);

    /* Animation setup */
    opacity: 0;
    animation: fadeInUp 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

/* Staggered delays */
.delay-1 {
    animation-delay: 0.1s;
}

.delay-2 {
    animation-delay: 0.2s;
}

.delay-3 {
    animation-delay: 0.3s;
}

.delay-4 {
    animation-delay: 0.4s;
}

.delay-5 {
    animation-delay: 0.5s;
}

.delay-6 {
    animation-delay: 0.6s;
}

.delay-7 {
    animation-delay: 0.7s;
}

/* Compact Hero - STATIC */
.hero {
    padding: var(--spacing-md);
    background: var(--color-bg-card);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    margin-bottom: var(--spacing-md);
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    border: 1px solid rgba(255, 255, 255, 0.3);
    /* Force Left Align and No Animation */
    text-align: left !important;
    opacity: 1 !important;
    animation: none !important;
    transition: none !important;
    transform: none !important;
}

.hero h1 {
    font-size: 2.2rem;
    font-weight: 800;
    line-height: 1.1;
    font-family: var(--font-stack-body);
    text-align: left;
}

.hero-lead {
    font-size: 1.1rem;
    color: var(--color-text);
    max-width: 95%;
    margin-bottom: 0;
}

.hero-details {
    font-size: 0.9rem;
    color: var(--color-text-light);
    font-weight: 500;
}

/* Timeline / Experience */
.timeline-item {
    display: flex;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-md);
    padding-bottom: var(--spacing-md);
    border-bottom: 1px solid var(--color-border);
}

.timeline-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.timeline-date {
    font-size: 0.85rem;
    color: var(--color-text-light);
    width: 120px;
    flex-shrink: 0;
    text-align: right;
    padding-top: 0.2rem;
    font-variant-numeric: tabular-nums;
    line-height: 1.4;
}

.timeline-content {
    flex-grow: 1;
}

.timeline-content h3 {
    font-size: 1.1rem;
    font-weight: 700;
    display: inline-block;
}

.timeline-content h4 {
    font-size: 1rem;
    font-weight: 500;
    color: var(--color-text-light);
    margin-bottom: 0.5rem;
}

.timeline-content ul {
    margin: 0;
    padding-left: 1.2rem;
    font-size: 0.95rem;
}

.timeline-content li {
    margin-bottom: 0.25rem;
}

.see-more-link {
    display: block;
    text-align: right;
    font-size: 0.9rem;
    margin-top: 0.5rem;
    font-weight: 500;
}

/* Compact Project Grid */
.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: var(--spacing-sm);
}

.project-card {
    background: rgba(255, 255, 255, 0.4);
    border: 1px solid var(--color-border);
    padding: var(--spacing-sm);
    border-radius: var(--radius-sm);
    transition: all 0.2s;
    color: inherit;
    display: block;
}

.project-card:hover {
    background: rgba(255, 255, 255, 0.7);
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

.project-meta {
    font-size: 0.75rem;
    text-transform: uppercase;
    color: var(--color-text-light);
    font-weight: 700;
    margin-bottom: 0.25rem;
    display: block;
}

.project-title {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
}

.project-title a {
    color: var(--color-text);
    text-decoration: underline;
}

.project-desc {
    font-size: 0.9rem;
    margin: 0;
}

/* Sidebar Lists */
.sidebar-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar-list li {
    padding: 0.4rem 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    display: flex;
    justify-content: space-between;
    font-size: 0.95rem;
}

.sidebar-list li:last-child {
    border: none;
}

.tag-group {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.tag {
    background: rgba(0, 50, 62, 0.08);
    color: var(--color-text);
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 500;
}

/* Compact Links List */
.link-list a {
    display: block;
    padding: 0.5rem;
    background: rgba(255, 255, 255, 0.3);
    border-radius: var(--radius-sm);
    margin-bottom: 0.5rem;
    text-decoration: none;
    font-weight: 500;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--color-text);
    transition: background 0.2s;
}

.link-list a:hover {
    background: rgba(255, 255, 255, 0.6);
    text-decoration: underline;
}

.link-note {
    font-size: 0.8rem;
    color: var(--color-text-light);
    font-weight: 400;
    text-decoration: none;
}

/* Footer */
.footer {
    text-align: center;
    padding-top: var(--spacing-md);
    border-top: 1px solid var(--color-border);
    margin-bottom: 2rem;
    color: var(--color-text);
    font-size: 0.9rem;

    /* Fade in footer last */
    opacity: 0;
    animation: fadeInUp 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
    animation-delay: 0.8s;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin: 1.5rem 0;
}

.social-icon {
    width: 40px;
    height: 40px;
    transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.social-icon:hover {
    transform: scale(1.2) rotate(5deg);
}

/* Global Link Styles */
a {
    color: var(--color-text);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

/* Print tweak */
@media print {
    body {
        background: none;
    }

    .dashboard-grid {
        display: block;
    }

    .sidebar {
        display: none;
    }
}