/* 
  Ozan Kilic Portfolio 
  Vanilla CSS - No Build Step
*/

:root {
    /* Colors - Light Theme (Default) */
    --bg-body: #F2F2F2;
    --bg-surface: #ffffff;
    --text-main: #121212;
    --text-muted: #555555;

    /* Brand Colors */
    --primary: #111111;
    --primary-text: #ffffff;
    --accent-color: #5D5FEF;

    /* Gradients */
    --grad-teal: linear-gradient(135deg, #2EABB2 0%, #1F8A90 100%);
    /* Non-transparent for better text contrast handling */
    --grad-dark: linear-gradient(135deg, #1a1a1a 0%, #000000 100%);
    --grad-hero: #F2F2F2;
    /* Solid color usually cleaner for hero in light mode, or subtle gradient */

    --border: rgba(0, 0, 0, 0.08);
    --nav-bg: rgba(242, 242, 242, 0.9);

    /* Spacing & Layout */
    --container-max: 1240px;
    --header-height: 80px;
    --gap-sm: 1rem;
    --gap-md: 2rem;
    --gap-lg: 6rem;
    /* Increased spacing for breathing room */
    --radius-md: 16px;
    --radius-lg: 40px;
    /* Increased for modern look */

    /* Animation */
    --ease-apple: cubic-bezier(0.25, 1, 0.5, 1);
    --transition-fast: 0.2s var(--ease-apple);
    --transition-medium: 0.6s var(--ease-apple);

    /* Typography */
    --font-heading: 'Inter', system-ui, -apple-system, sans-serif;
    --font-body: 'Inter', system-ui, -apple-system, sans-serif;
}

[data-theme="dark"] {
    --bg-body: #050505;
    --bg-surface: #121212;
    --text-main: #ffffff;
    --text-muted: #aaaaaa;

    --primary: #5D5FEF;
    --primary-text: #ffffff;

    --border: rgba(255, 255, 255, 0.1);
    --nav-bg: rgba(5, 5, 5, 0.9);

    --grad-teal: linear-gradient(135deg, #1A6B70 0%, #0F4548 100%);
    --grad-hero: #050505;
}

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-body);
    color: var(--text-main);
    line-height: 1.6;
    transition: background-color 0.3s ease, color 0.3s ease;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 1rem;
    letter-spacing: -0.02em;
}

h1 {
    font-size: clamp(3rem, 8vw, 6rem);
}

h2 {
    font-size: clamp(2rem, 5vw, 3.5rem);
}

h3 {
    font-size: 1.5rem;
}

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

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
    height: auto;
}

/* Utilities */
.container {
    width: 90%;
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 var(--gap-sm);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2rem;
    background-color: var(--primary);
    color: var(--primary-text);
    font-weight: 600;
    border-radius: 999px;
    /* Pill shape from screenshots */
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: none;
    /* Changed from uppercase to match screenshots */
    font-size: 1rem;
    letter-spacing: normal;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
    opacity: 0.95;
}

.btn:active {
    transform: translateY(0);
}

.btn-outline {
    background-color: transparent;
    border: 1px solid var(--text-main);
    color: var(--text-main);
}

.btn-outline:hover {
    background-color: var(--text-main);
    color: var(--bg-surface);
}

/* Fix for footer buttons in dark mode hovering */
/* In dark mode, bg-surface is dark. Hovering white text-main becomes white bg. Text becomes dark. 
   But user said "white on white". Likely inline styles overlaying. 
   We will ensure the social buttons work correctly. */
[data-theme="dark"] .btn-outline:hover {
    background-color: #ffffff;
    color: #000000 !important;
    /* Force black text on white hover in dark mode */
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--header-height);
    background: var(--nav-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 1000;
    border-bottom: 1px solid var(--border);
    transition: transform 0.3s ease;
}

[data-theme="dark"] .navbar {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
}

.nav-logo {
    display: block;
    height: 40px;
}

.nav-logo img {
    height: 100%;
    width: auto;
    object-fit: contain;
}

/* Invert logo based on theme if it's a black SVG/PNG */
/* Assuming logo is black: */
[data-theme="light"] .nav-logo img {
    filter: invert(1);
}

.nav-links {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-link {
    font-weight: 500;
    position: relative;
    color: var(--text-main);
    /* Ensure contrast */
    opacity: 0.7;
}

.nav-link:hover,
.nav-link.active {
    opacity: 1;
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: var(--accent);
}

/* Mobile Menu */
.nav-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    flex-direction: column;
    gap: 6px;
    z-index: 1002;
}

.nav-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background-color: var(--text-main);
    transition: 0.3s;
}

/* Hero Section */
/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: var(--header-height);
    position: relative;
    overflow: hidden;
    /* More Color: Soft Pastels + Primary Gradient */
    background:
        radial-gradient(circle at 10% 20%, rgba(32, 178, 170, 0.25) 0%, transparent 50%),
        radial-gradient(circle at 90% 80%, rgba(138, 43, 226, 0.2) 0%, transparent 50%),
        var(--grad-hero);
    background-size: 200% 200%;
    animation: gradientMove 15s ease infinite;
}

@keyframes gradientMove {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

[data-theme="dark"] .hero {
    /* More Color for Dark Mode */
    background:
        radial-gradient(circle at 20% 30%, rgba(46, 171, 178, 0.3) 0%, rgba(0, 0, 0, 0) 60%),
        radial-gradient(circle at 80% 70%, rgba(224, 195, 252, 0.2) 0%, rgba(0, 0, 0, 0) 60%),
        #050505;
}

.hero-content {
    position: relative;
    z-index: 2;
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

/* Enhancing Parallax Feel */
.bg-canvas {
    perspective: 1000px;
}

.orb {
    will-change: transform;
    opacity: 0.6;
}

[data-theme="dark"] .orb {
    opacity: 0.3;
}

/* Resume Page Specifics if any */


@media (min-width: 900px) {
    .hero-img-col {
        display: block;
    }
}

/* Mobile responsive hero adjustment in media query section later */


/* Background Animation Placeholder */
/* Background Orbs Animation */
.bg-canvas {
    position: fixed;
    /* Fixed so it moves with scroll 'parallax' style naturally or stays put */
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -1;
    pointer-events: none;
    overflow: hidden;
}

.orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.6;
    animation: float 20s infinite ease-in-out;
}

.orb-1 {
    top: -10%;
    left: -10%;
    width: 50vw;
    height: 50vw;
    background: radial-gradient(circle, rgba(65, 105, 225, 0.3) 0%, rgba(0, 0, 0, 0) 70%);
}

.orb-2 {
    bottom: -10%;
    right: -10%;
    width: 40vw;
    height: 40vw;
    background: radial-gradient(circle, rgba(255, 100, 100, 0.2) 0%, rgba(0, 0, 0, 0) 70%);
    animation-delay: -5s;
}

.orb-3 {
    top: 40%;
    left: 40%;
    width: 30vw;
    height: 30vw;
    background: radial-gradient(circle, rgba(50, 205, 50, 0.2) 0%, rgba(0, 0, 0, 0) 70%);
    animation-delay: -10s;
}

@keyframes float {

    0%,
    100% {
        transform: translate(0, 0) scale(1);
    }

    33% {
        transform: translate(30px, -50px) scale(1.1);
    }

    66% {
        transform: translate(-20px, 20px) scale(0.9);
    }
}

/* Highlights */
/* Sections */
.section {
    padding: var(--gap-lg) 0;
    position: relative;
    z-index: 1;
}

.section-teal {
    background: var(--grad-teal);
    color: white;
    border-radius: var(--radius-lg);
    margin: 2rem var(--gap-sm);
    padding: 4rem 2rem;
}

.section-teal h1,
.section-teal h2,
.section-teal p {
    color: white;
}

.section-teal {
    background: var(--grad-teal);
    color: white;
    /* Force white text for contrast on purple */
    border-radius: var(--radius-lg);
    margin: 2rem var(--gap-sm);
    padding: 6rem 2rem;
    text-align: center;
}

.section-teal h2,
.section-teal p {
    color: white;
}

.card-container {
    max-width: 800px;
    margin: 0 auto;
}

/* Removed inner background as requested */

/* Scroll Animation Listeners - Apple Style */
.reveal {
    opacity: 0;
    transform: scale(0.95) translateY(20px);
    filter: blur(10px);
    transition: all 0.8s var(--ease-apple);
}

.reveal.active {
    opacity: 1;
    transform: scale(1) translateY(0);
    filter: blur(0);
}

/* Cards General */
.highlight-card,
.project-card,
.skill-tag,
.gallery-item {
    border-radius: var(--radius-md);
}

.highlight-card {
    background: var(--bg-surface);
    padding: 2rem;
    border: 1px solid var(--border);
    transition: var(--transition-medium);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.02);
}

/* Numbered Service Cards */
.service-card {
    background: var(--bg-surface);
    padding: 2.5rem;
    border-radius: var(--radius-lg);
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 250px;
    border: 1px solid var(--border);
}

.service-number {
    font-size: 1.5rem;
    color: var(--text-muted);
    font-weight: 500;
    opacity: 0.5;
    margin-top: auto;
    align-self: flex-end;
}

.service-icon {
    width: 48px;
    height: 48px;
    background: #f0f0f0;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    font-size: 1.2rem;
}

[data-theme="dark"] .service-icon {
    background: #222;
}

/* Experience Cards (Logo + Text) */
.exp-card {
    background: var(--bg-surface);
    padding: 2rem;
    border-radius: var(--radius-md);
    display: flex;
    flex-direction: column;
    gap: 1rem;
    border: 1px solid var(--border);
}

.exp-header {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.exp-logo {
    width: 40px;
    height: 40px;
    object-fit: contain;
}

[data-theme="dark"] .exp-logo {
    filter: grayscale(1) invert(1);
}


.highlight-card:hover {
    transform: translateY(-5px);
}

/* Skills */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.skill-category h3 {
    margin-bottom: 1rem;
    font-size: 1.2rem;
    color: var(--accent);
}

.skill-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.skill-tag {
    display: inline-block;
    padding: 0.4rem 1rem;
    background: var(--bg-body);
    border: 1px solid var(--border);
    border-radius: 99px;
    font-size: 0.85rem;
    color: var(--text-muted);
    font-weight: 500;
    transition: all 0.2s ease;
}

[data-theme="dark"] .skill-tag {
    background: #1a1a1a;
    color: #e0e0e0;
    border-color: #333;
}

.skill-tag:hover {
    background: var(--text-main);
    color: var(--bg-surface);
    border-color: var(--text-main);
}

[data-theme="dark"] .skill-tag:hover {
    background: #ffffff;
    color: #111111;
}

/* Projects */
.projects-grid {
    display: grid;
    /* Default for projects: Responsive auto-fill */
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2rem;
    justify-content: center;
}

/* Services 2x2 Grid explicitly */
.services-grid-2x2 {
    display: grid;
    grid-template-columns: 1fr;
    /* Mobile */
    gap: 2rem;
}

@media (min-width: 900px) {
    .services-grid-2x2 {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Services 2x2 Grid explicitly */
.services-grid-2x2 {
    display: grid;
    grid-template-columns: 1fr;
    /* Mobile */
    gap: 2rem;
}

@media (min-width: 768px) {
    .services-grid-2x2 {
        grid-template-columns: repeat(2, 1fr);
    }
}

.project-card {
    background: var(--bg-surface);
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid var(--border);
    transition: transform var(--transition-medium), box-shadow var(--transition-medium);
    /* Ensure card doesn't get too wide even in single column */
    max-width: 500px;
    margin: 0 auto;
    /* Center in grid cell if needed */
    width: 100%;
}

.project-card:hover {
    transform: translateY(-5px);
}

.project-img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    background-color: var(--border);
    /* Placeholder color */
}

.project-body {
    padding: 1.5rem;
}

.project-tags {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* Gallery */
.gallery-grid {
    column-count: 3;
    /* Masonry effect */
    column-gap: 1.5rem;
}

.gallery-item {
    break-inside: avoid;
    margin-bottom: 1.5rem;
    position: relative;
    cursor: pointer;
    overflow: hidden;
    border-radius: 4px;
}

.gallery-item img {
    width: 100%;
    transition: transform 0.5s ease;
}

.gallery-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4);
    opacity: 0;
    transition: opacity 0.3s ease;
    display: flex;
    align-items: flex-end;
    padding: 1rem;
    color: white;
}

.gallery-item:hover img {
    transform: scale(1.05);
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}

/* Lightbox */
.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    z-index: 2000;
    display: none;
    justify-content: center;
    align-items: center;
    padding: 2rem;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.lightbox.active {
    display: flex;
    opacity: 1;
}

.lightbox-img {
    max-width: 90%;
    max-height: 85vh;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
    border-radius: 4px;
}

.lightbox-close {
    position: absolute;
    top: 2rem;
    right: 2rem;
    color: white;
    font-size: 2rem;
    cursor: pointer;
    background: none;
    border: none;
}

/* Contact */
.contact-container {
    max-width: 600px;
    margin: 0 auto;
    padding-top: 4rem;
}

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

.contact-label {
    font-weight: 600;
}

.contact-value {
    color: var(--text-muted);
    font-family: monospace;
    font-size: 1.1rem;
}

.copy-btn {
    background: none;
    border: 1px solid var(--border);
    padding: 0.4rem 0.8rem;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.8rem;
    margin-left: 1rem;
    color: var(--text-main);
    transition: background 0.2s;
}

.copy-btn:hover {
    background: var(--bg-surface);
}

/* Footer */
/* Footer */
footer {
    padding: 2rem 0;
    text-align: center;
    color: var(--text-muted);
    border-top: 1px solid var(--border);
    margin-top: 4rem;
}

/* Footer Link/Text adjustments if needed */
footer p {
    opacity: 0.9;
    font-weight: 500;
}

/* Scroll Animation Classes */
.reveal {
    opacity: 0;
    transform: scale(0.95) translateY(20px);
    filter: blur(10px);
    transition: all 0.8s var(--ease-apple);
}

.reveal.active {
    opacity: 1;
    transform: scale(1) translateY(0);
    filter: blur(0);
}




/* Resume Specific Styles */
.resume-header {
    padding: 8rem 0 4rem;
}

.resume-role {
    font-size: 1.25rem;
    color: var(--text-muted);
}

.resume-contact {
    margin-top: 1rem;
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.resume-section-title {
    margin-bottom: 2rem;
    border-bottom: 2px solid var(--border);
    padding-bottom: 1rem;
}

.resume-section-title.education {
    margin: 4rem 0 2rem;
}

.timeline-marker.education {
    background: var(--text-main);
}

.sidebar-list {
    list-style: none;
    padding: 0;
}

.sidebar-list-item {
    margin-bottom: 1.5rem;
}

.btn-full-width {
    width: 100%;
    justify-content: center;
}

/* Two Column Layout for Resume */
.resume-container {
    display: flex;
    flex-direction: column-reverse;
    gap: 4rem;
}

@media (min-width: 900px) {
    .resume-container {
        flex-direction: row;
        align-items: flex-start;
    }
}

.main-content {
    flex: 2;
}

.sidebar {
    flex: 1;
    min-width: 300px;
}

.timeline {
    position: relative;
    padding-left: 20px;
    border-left: 2px solid var(--border);
}

.timeline-item {
    position: relative;
    margin-bottom: 4rem;
    padding-left: 30px;
}

.timeline-marker {
    position: absolute;
    left: -29px;
    /* Adjust based on border width and marker size */
    top: 0;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--accent-color);
    border: 4px solid var(--bg-body);
}

.t-date {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
    display: block;
    font-weight: 600;
}

.t-title {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
}

.t-subtitle {
    font-size: 1.1rem;
    color: var(--text-main);
    margin-bottom: 1rem;
    font-weight: 600;
}

.t-desc ul {
    list-style: none;
    padding: 0;
}

.t-desc li {
    position: relative;
    padding-left: 1.5rem;
    margin-bottom: 0.75rem;
    color: var(--text-muted);
}

.t-desc li::before {
    content: '•';
    position: absolute;
    left: 0;
    color: var(--accent-color);
    font-weight: bold;
}

/* Sidebar Elements */
.sidebar-section {
    margin-bottom: 3rem;
}

.sidebar-title {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 1rem;
    border-bottom: 2px solid var(--border);
    padding-bottom: 0.5rem;
    display: inline-block;
}

.skill-tag-resume {
    display: inline-block;
    padding: 0.4rem 0.8rem;
    border: 1px solid var(--border);
    border-radius: 99px;
    font-size: 0.85rem;
    margin-right: 0.5rem;
    margin-bottom: 0.5rem;
    background: var(--bg-surface);
}




/* Mobile Responsive */
@media (max-width: 900px) {
    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 2rem;
    }

    .hero-actions {
        justify-content: center;
    }

    .hero-img-col {
        display: block;
        /* Show image on mobile, stacked below text */
        max-width: 400px;
        margin: 0 auto;
    }

    .hero-image-container {
        aspect-ratio: 3/4;
        /* Slightly taller aspect ratio for mobile */
    }

    .status-badge {
        margin-top: 2rem;
        /* Add breathing room at top on mobile */
    }
}

@media (max-width: 768px) {
    :root {
        --gap-lg: 3rem;
        --radius-lg: 24px;
    }

    h1 {
        font-size: 3rem;
    }

    .nav-toggle {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: var(--header-height);
        left: 0;
        width: 100%;
        height: calc(100vh - var(--header-height));
        background: var(--bg-body);
        flex-direction: column;
        justify-content: center;
        transform: translateX(100%);
        transition: transform 0.3s ease;
        padding: 2rem;
        border-top: 1px solid var(--border);
    }

    .nav-links.nav-open {
        transform: translateX(0);
    }

    .gallery-grid {
        column-count: 1;
    }

    .section-teal,
    .section-teal {
        padding: 3rem 1.5rem;
    }
}

/* Preferences */
@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }

    .reveal {
        opacity: 1;
        transform: none;
    }
}

/* Active state for project filter buttons */
.filter-btn.active,
.skill-tag.active {
    background-color: var(--primary);
    color: var(--primary-text);
    border-color: var(--primary);
}
/* --- Refactored Utility Classes --- */
.text-muted-small { color: var(--text-muted); }
.mt-2 { margin-top: 2rem; }
.full-width { width: 100%; }
.flex-1 { flex: 1; }
.flex-center { display: flex; align-items: center; }

/* Components Refactored from Inline Styles */
.status-badge {
    display: inline-block;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid var(--border);
    padding: 0.5rem 1rem;
    border-radius: 99px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    margin-bottom: 1.5rem;
    backdrop-filter: blur(5px);
}

.hero-title {
    line-height: 1.1;
    margin-bottom: 1.5rem;
}

/* Overriding or Extending hero-text if needed, but keeping separate to avoid conflict */
.hero-desc-large {
    font-size: 1.25rem;
    max-width: 500px;
    margin-bottom: 2.5rem;
    opacity: 0.8;
}

.hero-image-container {
    width: 100%;
    aspect-ratio: 4/5;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    background: #eee;
}

.hero-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.mission-title {
    font-size: clamp(2rem, 4vw, 3rem);
    line-height: 1.2;
}

.services-title {
    font-size: 3rem;
    max-width: 300px;
    line-height: 1;
    margin-bottom: 3rem;
}

.service-desc {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.section-surface {
    background: var(--bg-surface);
}

.section-header-flex {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 2rem;
}

.contact-title {
    font-size: clamp(2rem, 5vw, 3.5rem);
    margin-bottom: 1rem;
    line-height: 1.1;
}

.contact-desc {
    margin-bottom: 3rem;
    opacity: 0.8;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.contact-actions {
    max-width: 400px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.connect-label {
    margin-bottom: 1rem;
    font-weight: 500;
}

.social-row {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

.btn-dark {
    background: #222;
    color: white;
}
.btn-dark:hover {
    background: #000;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 8px 15px rgba(0,0,0,0.2);
}

.btn-outline-light {
    border-color: rgba(255, 255, 255, 0.4);
}
.btn-outline-light:hover {
    background-color: white;
    color: black !important;
}

.contact-intro {
    color: var(--text-muted);
    margin-bottom: 3rem;
}

.contact-value-row {
    display: flex;
    align-items: center;
}

/* Projects Page */
.page-header {
    padding-top: calc(var(--header-height) + 4rem);
}

.page-subtitle {
    color: var(--text-muted);
    max-width: 600px;
}

.projects-filter-container {
    margin-bottom: 2rem;
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

/* --- Project Interactions & Modal --- */

/* Hover Effect for Project Cards */
.project-img {
    transition: transform 0.6s var(--ease-apple);
    cursor: pointer;
}

.project-card:hover .project-img {
    transform: scale(1.05);
}

.project-card {
    overflow: hidden; /* Ensure zoom stays within bounds */
    border-radius: var(--radius-md); /* Ensure radius applies to overflow */
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: hidden; /* No scroll on body */
    background-color: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(10px);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modal.active {
    display: flex;
    opacity: 1;
    align-items: center;
    justify-content: center;
}

.modal-content-wrapper {
    position: relative;
    max-width: 90%;
    max-height: 90%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.modal-image {
    max-width: 100%;
    max-height: 80vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
}

.modal-info {
    margin-top: 1rem;
    text-align: center;
    color: white;
    max-width: 600px;
}

.modal-info h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.modal-info p {
    color: rgba(255,255,255,0.8);
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

/* Modal Navigation */
.modal-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,0.1);
    color: white;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    transition: background 0.2s;
    backdrop-filter: blur(5px);
    z-index: 2001; /* Above image */
}

.modal-nav:hover {
    background: rgba(255,255,255,0.2);
}

.modal-prev { left: 20px; }
.modal-next { right: 20px; }

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 2rem;
    color: white;
    background: transparent;
    border: none;
    cursor: pointer;
    z-index: 2002;
    padding: 10px;
    line-height: 1;
}

/* Mobile Adjustments */
@media (max-width: 768px) {
    .modal-nav {
        display: none; /* Hide arrows on mobile, rely on swipe */
    }
    
    .modal-image {
        max-height: 70vh;
    }
}

/* Modal Layout Adjustments */
#modal-links {
    display: flex; 
    gap: 1rem; 
    justify-content: center;
}

/* Large Screens: Modal Layout Alignment */
@media (min-width: 768px) {
    .modal-info {
        display: flex;
        flex-wrap: wrap;
        text-align: left;
        align-items: center;
        width: 100%;
        max-width: 800px; /* Wider to accommodate side-by-side */
    }

    .modal-info h3,
    .modal-info p {
        width: 100%; /* Title and desc take full width top rows roughly? Or maybe split? */
        /* User asked: "align text to left and button to the right" */
        /* Let's Try: Text (Title + Desc) on Left, Button group on Right */
    }
    
    .modal-info {
        display: grid;
        grid-template-columns: 1fr auto;
        gap: 2rem;
        align-items: center;
    }

    .modal-info h3 {
        grid-column: 1;
        margin-bottom: 0.25rem;
    }
    
    .modal-info p {
        grid-column: 1;
        margin-bottom: 0;
    }

    #modal-links {
        grid-column: 2;
        grid-row: 1 / span 2; /* Span both title and desc rows */
        justify-content: flex-end;
    }
}
