/* =========================================
   1. THEME VARIABLES (The Control Center)
   ========================================= */
:root {
    /* --- LIGHT MODE (Default) --- */
    /* Primary: Indigo (Professional, Tech-oriented) */
    --clr-primary: #4f46e5;
    --clr-primary-hover: #4338ca;
    --clr-primary-light: #e0e7ff;

    /* Neutrals */
    --clr-bg-body: #f8fafc;
    /* Slate 50 (Soft Grey-White) */
    --clr-bg-surface: #ffffff;
    /* Pure White */
    --clr-text-main: #0f172a;
    /* Slate 900 (Dark) */
    --clr-text-muted: #64748b;
    /* Slate 500 (Grey) */
    --clr-border: #e2e8f0;
    /* Light Border */

    /* Shadows & Shapes */
    --radius-md: 12px;
    --radius-pill: 50px;
    --shadow-sm: 0 1px 3px 0 rgb(0 0 0 / 0.1);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1);
    --shadow-glow: 0 0 15px rgba(79, 70, 229, 0.3);

    /* Animation */
    --transition-fast: 0.2s ease-in-out;

    /* --- TIMELINE VARIABLES --- */
    --tl-icon-size: 65px;
    --tl-line-width: 2px;
    --tl-gap: 20px;
    --tl-cavity-depth: 26px;
    /* Horizontal depth of the cutout */
    --tl-cavity-height: 38px;
    /* Vertical height of the cutout */
}

/* --- DARK MODE OVERRIDES --- */
[data-theme="dark"] {
    --clr-primary: #818cf8;
    /* Lighter Indigo */
    --clr-primary-hover: #a5b4fc;
    --clr-primary-light: #1e293b;
    /* Dark Indigo background */

    --clr-bg-body: #0f172a;
    /* Deep Slate */
    --clr-bg-surface: #1e293b;
    /* Lighter Slate */
    --clr-text-main: #f1f5f9;
    /* White-ish text */
    --clr-text-muted: #94a3b8;
    --clr-border: #334155;
    /* Dark Grey Border */

    --shadow-sm: 0 1px 3px 0 rgb(0 0 0 / 0.5);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.5);
}

/* =========================================
   2. GLOBAL RESET & BASE
   ========================================= */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--clr-bg-body);
    color: var(--clr-text-main);
    line-height: 1.6;
    transition: background-color 0.3s ease, color 0.3s ease;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    padding-top: 100px;
}

/* Typography Defaults */
h1,
h2,
h3,
h4 {
    color: var(--clr-text-main);
    font-weight: 700;
    line-height: 1.2;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-fast);
}

ul {
    list-style: none;
}

/* Layout Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    width: 100%;
}

/* =========================================
   3. NAVIGATION BAR
   ========================================= */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    margin-bottom: 0;
    background: var(--clr-bg-surface);
    border-radius: 0 0 var(--radius-md) var(--radius-md);
    border-bottom: 1px solid var(--clr-border);
    box-shadow: var(--shadow-sm);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    margin: 0 auto;
    max-width: 1200px;
    /* Matches container max-width */
    width: calc(100% - 40px);
    /* Matches container padding (20px each side) */
    z-index: 1000;
    transition: transform 0.3s ease-in-out, background-color 0.3s ease, box-shadow 0.3s ease;
}

.navbar--hidden {
    transform: translateY(-100%);
    /* Moves it up out of view */
    box-shadow: none;
}

.nav-left {
    display: flex;
    gap: 25px;
    align-items: center;
}

.nav-link {
    font-weight: 600;
    color: var(--clr-text-muted);
    position: relative;
    padding: 5px 0;
}

.nav-link:hover,
.nav-link.active {
    color: var(--clr-primary);
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 0;
    right: auto;
    background-color: var(--clr-primary);
    transition: width 0.3s;
}

.nav-link.active::after {
    width: 100%;
}

.nav-link:hover::after {
    width: 100%;
}

html[dir="rtl"] .nav-link::after {
    left: auto;
    right: 0;
}

.nav-right {
    display: flex;
    gap: 15px;
    align-items: center;
}

/* =========================================
   4. HERO SECTION
   ========================================= */
.hero-container {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 45px;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 5rem;
}

.hero-profile {
    display: flex;
    align-items: center;
    gap: 20px;
}

.profile-img {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--clr-bg-surface);
    box-shadow: var(--shadow-md);
    cursor: pointer;
}

.profile-info h1 {
    font-size: 2.5rem;
    margin-bottom: 0.2rem;
}

.location-text {
    font-size: 1rem;
    color: var(--clr-text-muted);
    font-weight: 500;
}

.hero-socials {
    display: flex;
    gap: 15px;
}

.social-btn {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background-color: transparent;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: transparent;
    box-shadow: var(--shadow-sm);
    transition: var(--transition-fast);
}

.social-btn img {
    width: 100%;
    height: 100%;
    border-radius: 8px;
}

.social-btn:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.hero-context {
    text-align: center;
    margin-bottom: 36px;
    padding: 0 20px;
}

.hero-title {
    font-size: 3.5rem;
    color: var(--clr-primary);
    margin-bottom: 10px;
    letter-spacing: -1px;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--clr-text-muted);
    margin-bottom: 25px;
    font-weight: 400;
}

.hero-actions {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 140px;
}

/* --- Compact Skill Card (The Preview) --- */
.home-skills-preview {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    align-content: center;
    gap: 15px;
    margin-top: 5px;
    margin-bottom: 30px;
    margin-left: auto;
    margin-right: auto;
    max-width: 750px;
}

.skill-card.compact {
    min-height: auto;
    padding: 0.6rem 1rem;
    gap: 10px;
    background: var(--clr-bg-surface);
    border: 1px solid var(--clr-border);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    opacity: 0.85;
    justify-content: center;
    align-items: center;
    text-align: center;
    max-width: 180px;
    min-width: 150px;
}

.skill-card.compact .skill-icon {
    width: 30px;
    height: 30px;
}

.skill-card.compact .skill-text {
    display: flex;
    align-items: center;
}

.skill-card.compact .skill-text strong {
    font-size: 0.9rem;
    margin-bottom: 0;
}

/* =========================================
   RESUME PAGE STYLES
   ========================================= */

/* --- Controls Bar --- */
.controls-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding: 10px 0;
    border-bottom: 1px solid var(--clr-border);
}

.view-toggle {
    display: flex;
    background: var(--clr-bg-surface);
    border: 1px solid var(--clr-border);
    border-radius: var(--radius-pill);
    padding: 4px;
    gap: 5px;
}

.chip {
    padding: 6px 16px;
    border-radius: var(--radius-pill);
    font-size: 0.9rem;
    cursor: pointer;
    border: none;
    background: transparent;
    color: var(--clr-text-muted);
    transition: var(--transition-fast);
}

.chip:hover {
    color: var(--clr-primary);
}

.chip.active {
    background-color: var(--clr-primary-light);
    color: var(--clr-primary);
    font-weight: 600;
}

/* Download Dropdown */
.download-dropdown {
    position: relative;
    display: inline-block;
}

.download-dropdown::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    height: 10px;
}

.dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 50%;
    right: auto;
    margin-left: -80px;

    margin-top: 5px;
    background-color: var(--clr-bg-surface);
    min-width: 160px;
    box-shadow: var(--shadow-md);
    border-radius: var(--radius-md);
    border: 1px solid var(--clr-border);
    z-index: 50;
    overflow: hidden;
}

.download-dropdown:hover .dropdown-menu {
    display: block;
    animation: fadeIn 0.2s ease-in forwards;
}

.dropdown-item {
    display: block;
    padding: 10px 15px;
    color: var(--clr-text-main);
    font-size: 0.9rem;
    transition: background 0.2s;
}

.dropdown-item:hover {
    background-color: var(--clr-bg-body);
    color: var(--clr-primary);
}

/* --- Tab Bar --- */
.tab-bar {
    display: flex;
    justify-content: space-evenly;
    align-items: center;
    background-color: var(--clr-bg-surface);
    border: 1px solid var(--clr-border);
    border-radius: var(--radius-pill);
    width: 95%;
    padding: 6px;
    gap: 5px;
    margin: 0 auto 40px auto;
}

.tab-btn {
    flex: 1;
    text-align: center;
    background: transparent;
    border: none;
    border-radius: var(--radius-pill);
    border-bottom: 3px solid transparent;
    padding: 10px 0;
    font-size: 1rem;
    font-weight: 500;
    color: var(--clr-text-muted);
    cursor: pointer;
    transition: var(--transition-fast);
}

.tab-btn:hover {
    color: var(--clr-primary);
    background-color: var(--clr-bg-body);
}

.tab-btn.active {
    background-color: var(--clr-primary-light);
    color: var(--clr-primary);
    border-bottom: none;
    box-shadow: var(--shadow-sm);
    font-weight: 700;
}

.tab-content {
    display: none;
    max-width: 800px;
    width: calc(100% - 40px);
    margin: 0 auto;
    animation: fadeIn 0.3s ease-in;
}

.tab-content.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(5px);
    }

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

/* =========================================
   5. SKILLS STACK STYLING
   ========================================= */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 15px;
    margin-bottom: 30px;
    padding: 0, 2rem;
}

.section-title {
    margin-top: 2rem;
    margin-bottom: 1rem;
    padding: 0 2rem;
    position: relative;
    z-index: 1;
}

.skill-card {
    background: var(--clr-bg-surface);
    border: 1px solid var(--clr-border);
    border-radius: var(--radius-md);
    padding: 1.2rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    box-shadow: var(--shadow-sm);
    min-height: 58px;
}

.skill-card:hover {
    transform: translateY(-4px);
    border-color: var(--clr-primary);
    box-shadow: var(--shadow-md);
}

.skill-icon {
    width: 48px;
    height: 48px;
    object-fit: contain;
    flex-shrink: 0;
}

.skill-text {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.skill-text strong {
    display: block;
    font-size: 1.05rem;
    color: var(--clr-text-main);
    margin-bottom: 0.15rem;
}

.skill-text p {
    font-size: 0.75rem;
    color: var(--clr-text-muted);
    margin: 0;
    line-height: 1.3;
}

.skill-card:not(:has(img)) {
    justify-content: center;
    text-align: center;
    border-left: 4px solid var(--clr-primary);
}

.skill-card:not(:has(img)) .skill-text {
    align-items: center;
}

/* =========================================
   6. EXPERIENCE & EDUCATION TIMELINE
   ========================================= */

.timeline-container {
    position: relative;
    max-width: 900px;
    width: 100%;
    margin: 0 auto 50px auto;
}

/* --- The Vertical Line --- */
.timeline-container::before {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    width: var(--tl-line-width);
    background-color: var(--clr-border);
    /* Centering handled in LTR/RTL blocks below */
}

/* --- Item Wrapper --- */
.job-item {
    position: relative;
    margin-bottom: 40px;
    display: flex;
    align-items: center;
}

/* --- The Icon --- */
.timeline-icon {
    position: absolute;
    width: var(--tl-icon-size);
    height: var(--tl-icon-size);
    border-radius: 50%;
    background: var(--clr-bg-surface);
    border: 2px solid var(--clr-border);
    overflow: hidden;
    z-index: 2;
    box-shadow: var(--shadow-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s, border-color 0.2s;
    cursor: pointer;
}

.timeline-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* --- The Card with the "Cavity" --- */
.job-card {
    position: relative;
    width: 100%;
    padding: 1.5rem 2rem;
    border-radius: var(--radius-md);
    color: var(--clr-text-main);
    filter: drop-shadow(var(--shadow-sm));
    transition: var(--transition-fast);
}

.job-card:hover {
    filter: drop-shadow(var(--shadow-md));
}

/* Header Layout (Role Left, Date Right) */
.job-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: nowrap;
    margin-bottom: 0.5rem;
    gap: 15px;
}

.job-info {
    display: flex;
    flex-direction: column;
}

.job-role {
    margin: 0;
    font-size: 1.2rem;
    color: var(--clr-text-main);
    line-height: 1.2;
}

/* Clickable Company Name */
.job-company {
    display: block;
    font-size: 1rem;
    color: var(--clr-primary);
    /* Primary color indicates link */
    font-weight: 600;
    margin-top: 4px;
    text-decoration: none;
    transition: opacity 0.2s;
}

.job-company:hover {
    opacity: 0.8;
    text-decoration: underline;
}

.timeline-date {
    font-size: 0.95rem;
    color: var(--clr-text-muted);
    font-weight: 500;
    background: transparent;
    border: none;
    padding: 0;
    margin-top: 2px;
    white-space: nowrap;
}

.job-card h3 {
    margin: 0 0 5px 0;
    font-size: 1.2rem;
    color: var(--clr-text-main);
}

.job-card .timeline-date {
    display: inline-block;
    font-size: 0.85rem;
    color: var(--clr-primary);
    font-weight: 600;
    margin-bottom: 12px;
    background: var(--clr-primary-light);
    padding: 4px 10px;
    border-radius: var(--radius-pill);
}

.job-card .timeline-company {
    display: block;
    font-size: 1rem;
    color: var(--clr-text-muted);
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.job-card p {
    margin: 0;
    line-height: 1.6;
    color: var(--clr-text-main);
    white-space: pre-line;
}

/* =========================================
   7. SIMPLE RESUME VIEW (Plain Mode)
   ========================================= */
.plain-container {
    background-color: var(--clr-bg-surface);
    border: 1px solid var(--clr-border);
    border-radius: var(--radius-md);
    padding: 3rem;
    max-width: 900px;
    margin: 0 auto 50px auto;
    box-shadow: var(--shadow-sm);
    font-family: 'Segoe UI', sans-serif;
    color: var(--clr-text-main);
}

.plain-header {
    text-align: center;
    margin-bottom: 2rem;
}

.plain-header h1 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.plain-links a {
    color: var(--clr-primary);
    text-decoration: none;
    font-weight: 500;
}

.plain-links a:hover {
    text-decoration: underline;
}

.plain-divider {
    border: 0;
    border-top: 1px solid var(--clr-border);
    margin: 2rem 0;
}

.plain-section {
    margin-bottom: 2.5rem;
}

.plain-section h2 {
    font-size: 1.1rem;
    color: var(--clr-text-muted);
    border-bottom: 2px solid var(--clr-border);
    padding-bottom: 5px;
    margin-bottom: 1.5rem;
    letter-spacing: 1px;
}

.plain-item {
    margin-bottom: 2.25rem;
}

.plain-item-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.2rem;
}

.plain-item-header strong {
    font-size: 1.1rem;
    color: var(--clr-text-main);
}

.plain-company {
    display: inline-block;
    color: var(--clr-primary);
    font-weight: 600;
    font-size: 0.95rem;
    margin-bottom: 0.5rem;
    text-decoration: none;
    /* No underline by default */
    cursor: pointer;
}

.plain-company:hover {
    text-decoration: underline;
    opacity: 0.8;
}

.plain-item p {
    color: var(--clr-text-muted);
    line-height: 1.6;
}

.plain-skills-list {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.plain-skill-row {
    line-height: 1.5;
}

.plain-skill-cat {
    font-weight: 700;
    color: var(--clr-text-main);
    margin-right: 8px;
    /* Space after colon in LTR */
    margin-left: 8px;
    /* Space after colon in RTL */
}

.plain-skill-items {
    color: var(--clr-text-muted);
}

/* =========================================
   8. MODAL (Popup) STYLES
   ========================================= */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    /* Dimmed background */
    backdrop-filter: blur(5px);
    /* Modern frosted glass effect */
    z-index: 2000;
    /* Above navbar (which is 1000) */
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.modal-overlay.open {
    opacity: 1;
    visibility: visible;
}

.modal-window {
    background-color: var(--clr-bg-surface);
    width: 90%;
    max-width: 1000px;
    height: 85vh;
    border-radius: var(--radius-md);
    border: 1px solid var(--clr-border);
    box-shadow: var(--shadow-md);
    display: flex;
    flex-direction: column;
    position: relative;
    transform: scale(0.95);
    transition: transform 0.3s ease;
}

.modal-overlay.open .modal-window {
    transform: scale(1);
}

.modal-header {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--clr-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-title {
    margin: 0;
    font-size: 1.25rem;
    color: var(--clr-text-main);
}

.modal-close-btn {
    background: transparent;
    border: none;
    font-size: 2rem;
    color: var(--clr-text-muted);
    cursor: pointer;
    line-height: 1;
    transition: color 0.2s;
    padding: 0 10px;
}

.modal-close-btn:hover {
    color: var(--clr-primary);
}

.modal-body {
    flex-grow: 1;
    background-color: var(--clr-bg-body);
    overflow: hidden;
    border-bottom-left-radius: var(--radius-md);
    border-bottom-right-radius: var(--radius-md);
}

.modal-iframe {
    width: 100%;
    height: 100%;
    border: none;
    display: block;
}

/* =========================================
   9. DIRECTION HANDLING (LTR vs RTL)
   ========================================= */

/* --- LTR (English) --- */
html[dir="ltr"] .timeline-container {
    padding-left: calc(var(--tl-icon-size) / 2);
}

html[dir="ltr"] .timeline-container::before {
    left: calc(var(--tl-icon-size) / 2);
    transform: translateX(-50%);
}

html[dir="ltr"] .timeline-icon {
    left: 0;
    transform: translateX(-50%);
}

html[dir="ltr"] .job-card {
    margin-left: var(--tl-gap);
    /* Cutout on the LEFT */
    background: radial-gradient(ellipse var(--tl-cavity-depth) var(--tl-cavity-height) at 0% 50%,
            transparent 99%,
            var(--clr-bg-surface) 100%);
    padding-left: 45px;
}

html[dir="ltr"] .plain-skill-cat {
    margin-left: 0;
}

html[dir="ltr"] .plain-item-header {
    margin-right: 3rem;
    margin-left: 0;
}

/* --- RTL (Hebrew) --- */
html[dir="rtl"] .timeline-container {
    padding-right: calc(var(--tl-icon-size) / 2);
}

html[dir="rtl"] .timeline-container::before {
    right: calc(var(--tl-icon-size) / 2);
    transform: translateX(50%);
}

html[dir="rtl"] .timeline-icon {
    right: 0;
    transform: translateX(50%);
}

html[dir="rtl"] .job-card {
    margin-right: var(--tl-gap);
    /* Cutout on the RIGHT */
    background: radial-gradient(ellipse var(--tl-cavity-depth) var(--tl-cavity-height) at 100% 50%,
            transparent 99%,
            var(--clr-bg-surface) 100%);
    padding-right: 45px;
}

html[dir="rtl"] .plain-skill-cat {
    margin-right: 0;
}

html[dir="rtl"] .plain-item-header {
    margin-right: 0;
    margin-left: 3rem;
}


/* =========================================
   10. GLOBAL COMPONENTS
   ========================================= */
.btn {
    display: inline-block;
    padding: 0.8rem 2rem;
    border-radius: var(--radius-pill);
    font-weight: 600;
    cursor: pointer;
    border: none;
    font-size: 1rem;
    transition: var(--transition-fast);
}

.btn-primary {
    background-color: var(--clr-primary);
    color: #ffffff;
    border: 2px solid var(--clr-primary);
}

.btn-primary:hover {
    background-color: var(--clr-primary-hover);
    border-color: var(--clr-primary-hover);
    box-shadow: var(--shadow-glow);
}

.btn-outline {
    background-color: transparent;
    border: 2px solid var(--clr-primary);
    color: var(--clr-primary);
}

.btn-outline:hover {
    background-color: var(--clr-primary);
    color: #ffffff;
    box-shadow: var(--shadow-glow);
}

.icon-btn {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.2rem;
    padding: 8px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--clr-text-main);
    transition: transform 0.2s;
}

.icon-btn:hover {
    background-color: var(--clr-border);
    transform: scale(1.1);
}

/* =========================================
   11. PDF VIEWER (Preview Mode)
   ========================================= */
.pdf-container {
    width: 100%;
    height: 1000px;
    /* Fixed height for the PDF viewer */
    max-height: 150vh;
    background-color: var(--clr-bg-surface);
    border: 1px solid var(--clr-border);
    border-radius: var(--radius-md);
    overflow: hidden;
    margin-bottom: 50px;
    box-shadow: var(--shadow-sm);
}

.pdf-container iframe {
    width: 100%;
    height: 100%;
    border: none;
}

/* Responsive adjustment for PDF height */
@media (max-width: 768px) {
    .pdf-container {
        height: 500px;
    }
}

/* =========================================
   12. FOOTER
   ========================================= */
.footer {
    margin-top: auto;
    padding: 2rem 0;
    margin: 100px 0 0;
    border-top: 2px solid var(--clr-border);
    background-color: transparent;
    color: var(--clr-text-muted);
}

.footer-links {
    margin-top: 10px;
}

.footer-links a {
    color: var(--clr-primary);
    font-weight: 600;
    margin: 0 5px;
}

.footer-links a:hover {
    text-decoration: underline;
}

.footer-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 0 10px;
    color: var(--clr-text-muted);
    font-weight: 500;
}

.footer-link img {
    width: 20px;
    height: 20px;
}

/* =========================================
   13. UTILITIES & HELPERS
   ========================================= */
.text-center {
    text-align: center;
}

@media (max-width: 768px) {
    .navbar {
        flex-direction: column;
        gap: 15px;
    }

    .nav-left {
        width: 100%;
        justify-content: center;
        flex-wrap: wrap;
    }

    .hero-container {
        gap: 2rem;
        flex-direction: column;
        text-align: center;
    }

    .hero-profile {
        flex-direction: column;
        text-align: center;
    }
}

/* =========================================
   14. CUSTOM SCROLLBAR
   ========================================= */

/* Firefox */
* {
    scrollbar-width: thin;
    scrollbar-color: var(--clr-text-muted) var(--clr-bg-body);
}

/* Chrome, Edge, Safari */
::-webkit-scrollbar {
    width: 12px;
    /* Width of the vertical scrollbar */
}

::-webkit-scrollbar-track {
    background: var(--clr-bg-body);
    /* Matches page background */
}

::-webkit-scrollbar-thumb {
    background-color: var(--clr-border);
    /* Subtle grey by default */
    border-radius: 20px;
    /* Roundness */
    border: 3px solid var(--clr-bg-body);
    /* Creates a "padding" effect around the thumb */
}

::-webkit-scrollbar-thumb:hover {
    background-color: var(--clr-primary-hover);
    /* Brand color on hover */
}

/* =========================================
   ANIMATION REFINEMENTS (Appended Overrides)
   ========================================= */

/* --- 1. Timeline Icons Hover Tilt --- */
.timeline-icon img {
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.timeline-icon:hover img {
    transform: scale(1.15) rotate(-4deg);
}


/* --- 2. Skill Cards Shine Animation --- */
.skill-card {
    position: relative;
    overflow: hidden;
    /* Contains the shine within the card's rounded borders */
}

/* The Shine Element */
.skill-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    /* A translucent white gradient fading out on the edges */
    background: linear-gradient(to right,
            rgba(255, 255, 255, 0) 0%,
            rgba(255, 255, 255, 0.4) 50%,
            rgba(255, 255, 255, 0) 100%);
    transform: skewX(-25deg);
    z-index: 1;
}

/* Adjust the shine for Dark Mode so it's not blindingly bright */
[data-theme="dark"] .skill-card::before {
    background: linear-gradient(to right,
            rgba(255, 255, 255, 0) 0%,
            rgba(255, 255, 255, 0.15) 50%,
            rgba(255, 255, 255, 0) 100%);
}

/* Trigger the shine animation on hover */
.skill-card:hover::before {
    animation: shineSweep 0.75s ease-out forwards;
}

@keyframes shineSweep {
    0% {
        left: -100%;
    }

    100% {
        left: 200%;
    }
}

/* Override the old hover state: remove border color change */
.skill-card:hover {
    transform: translateY(-4px);
    /* Keep the float for main cards */
    box-shadow: var(--shadow-md);
    border-color: var(--clr-border);
    /* Resets to default border instead of primary */
}

/* --- 3. Fix Preview Skills (Compact) --- */
/* Prevent the preview cards on the home page from translating up */
.skill-card.compact:hover {
    transform: none;
    /* Stops the upward float */
    box-shadow: var(--shadow-sm);
    /* Keeps the flat, resting shadow */
}