:root {
    --color-primary: #38bdf8;
    --color-primary-container: #3498db;
    --color-secondary-container: #a855f7;
    --color-background: #000000;
    --color-surface: #080808;
    --color-surface-raised: #0A0A0A;
    --color-text-main: #e2e2e2;
    --color-text-muted: #bfc7d2;
    --color-text-dark: #666666;
    --border-light: rgba(255, 255, 255, 0.1);
    --border-medium: rgba(255, 255, 255, 0.2);
    --border-strong: rgba(255, 255, 255, 0.4);
    --font-editorial: 'Instrument Serif', serif;
    --font-body: 'Inter', sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
}

/* Base resets & styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--color-background);
    color: var(--color-text-main);
    font-family: var(--font-body);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

::selection {
    background-color: var(--color-primary-container);
    color: #ffffff;
}

/* Custom Scrollbars */
/* WebKit browsers (Chrome, Safari, Edge, Opera) */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: #121212;
}

::-webkit-scrollbar-thumb {
    background: #444444;
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: #666666;
}

::-webkit-scrollbar-button {
    display: none;
}


a {
    text-decoration: none;
    color: inherit;
}

/* Material Icons */
.material-symbols-outlined {
    font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
}

/* Background Noise Overlay */
.noise-overlay {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: -1;
    opacity: 0.2;
    mix-blend-mode: overlay;
    background-image: url('data:image/svg+xml,%3Csvg viewBox=%220 0 200 200%22 xmlns=%22http://www.w3.org/2000/svg%22%3E%3Cfilter id=%22noiseFilter%22%3E%3CfeTurbulence type=%22fractalNoise%22 baseFrequency=%220.65%22 numOctaves=%223%22 stitchTiles=%22stitch%22/%3E%3C/filter%3E%3Crect width=%22100%25%22 height=%22100%25%22 filter=%22url(%23noiseFilter)%22/%3E%3C/svg%3E');
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 50;
    border-bottom: 1px solid var(--border-light);
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(12px);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 1.5rem;
    height: 5rem;
}

@media (min-width: 768px) {
    .navbar {
        padding: 0 3rem;
    }
}

.nav-brand-container {
    display: flex;
    align-items: center;
    gap: 1rem;
    text-decoration: none;
    transition: opacity 0.3s ease;
}

.nav-brand-container:hover {
    opacity: 0.8;
}

.brand-logo {
    height: 2.5rem;
    width: auto;
    object-fit: contain;
}

.nav-brand {
    font-family: var(--font-editorial);
    font-style: italic;
    font-size: 1.7rem;
    color: #ffffff;
}

.nav-links {
    display: none;
    gap: 2rem;
}

@media (min-width: 768px) {
    .nav-links {
        display: flex;
    }
}

.nav-link {
    font-family: var(--font-mono);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-size: 0.78rem;
    transition: color 0.3s ease;
}

.nav-link.lens {
    color: var(--color-primary);
}

.nav-link.logic {
    color: var(--color-secondary-container);
}

.nav-link:hover {
    color: #ffffff;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.lang-selector {
    font-family: var(--font-mono);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.5);
    display: flex;
    gap: 0.5rem;
}

.lang-link {
    color: #ffffff;
    transition: color 0.3s ease;
}

.lang-link:hover {
    color: var(--color-primary);
}

/* Main Content Area */
.main-content {
    flex-grow: 1;
    max-width: 1600px;
    margin: 0 auto;
    padding-top: 5rem;
}

.container {
    max-width: 100rem;
    margin: 0 auto;
    padding: 0 1.5rem;
}

@media (min-width: 768px) {
    .container {
        padding: 0 3rem;
    }
}

/* Hero Section */
.hero-section {
    padding: 4rem 0;
}

@media (min-width: 768px) {
    .hero-section {
        padding: 8rem 0;
    }
}

@media (min-width: 1024px) {
    .hero-section {
        padding: 11rem 0;
    }
}

.hero-title {
    font-family: var(--font-editorial);
    font-size: 3rem;
    line-height: 1.15;
    font-style: italic;
    letter-spacing: -0.05em;
    margin-bottom: 1rem;
    background: linear-gradient(to bottom right, var(--color-primary), #ffffff, var(--color-secondary-container));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

@media (min-width: 480px) {
    .hero-title {
        font-size: 3.5rem;
    }
}

@media (min-width: 768px) {
    .hero-title {
        font-size: 6rem;
    }
}

@media (min-width: 1024px) {
    .hero-title {
        font-size: 7rem;
    }
}

.hero-subtitle {
    font-size: 1rem;
    color: var(--color-text-muted);
    max-width: 42rem;
    line-height: 1.5;
    opacity: 0.9;
}

@media (min-width: 768px) {
    .hero-subtitle {
        font-size: 1.2rem;
    }
}

/* Cards Container */
.cards-container {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    padding-bottom: 4rem;
}

@media (min-width: 768px) {
    .cards-container {
        gap: 4rem;
        padding-bottom: 8rem;
    }
}

/* Photography Card */
.photo-card {
    position: relative;
    width: 100%;
    min-height: 380px;
    border-radius: 1rem;
    overflow: hidden;
    border: 1px solid var(--border-medium);
    background-color: var(--color-surface);
    transition: all 0.5s ease;
    box-shadow: 0 0 1px 1px rgba(255, 255, 255, 0.1), 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

@media (min-width: 768px) {
    .photo-card {
        min-height: 450px;
    }
}

.photo-card:hover {
    box-shadow: 0 0 20px -5px rgba(255, 255, 255, 0.15);
}

.photo-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
    background-size: cover;
    background-position: center;
    transition: transform 1s ease;
    mix-blend-mode: luminosity;
    opacity: 0.5;
    background-image: url('pictures/bg-photo.webp');
}

.photo-card:hover .photo-bg {
    transform: scale(1.05);
}

.photo-gradient {
    position: absolute;
    inset: 0;
    z-index: 10;
    background: linear-gradient(to top, #000000, rgba(0, 0, 0, 0.6), transparent);
}

.card-content {
    position: relative;
    z-index: 20;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 1.5rem;
}

@media (min-width: 768px) {
    .card-content {
        padding: 3.5rem;
    }
}

.card-overline {
    font-family: var(--font-mono);
    letter-spacing: 0.3em;
    text-transform: uppercase;
    font-weight: bold;
    margin-bottom: 1rem;
}

.card-overline.primary {
    color: var(--color-primary);
}

.card-overline.secondary {
    color: var(--color-secondary-container);
}

.card-title {
    font-family: var(--font-editorial);
    font-size: 2.5rem;
    color: #ffffff;
    margin-bottom: 1.5rem;
    font-style: italic;
}

@media (min-width: 768px) {
    .card-title {
        font-size: 4.5rem;
    }
}

.card-title-tech {
    font-family: var(--font-body);
    font-size: 2rem;
    color: #ffffff;
    margin-bottom: 2rem;
    letter-spacing: -0.05em;
}

@media (min-width: 768px) {
    .card-title-tech {
        font-size: 3rem;
    }
}

.card-desc {
    color: var(--color-text-muted);
    max-width: 36rem;
    margin-bottom: 2.5rem;
    font-size: 0.875rem;
    line-height: 1.625;
}

@media (min-width: 768px) {
    .card-desc {
        font-size: 1.125rem;
    }
}

.card-link {
    display: inline-flex;
    align-items: center;
    border-bottom: 2px solid;
    padding-bottom: 0.25rem;
    width: fit-content;
    transition: all 0.3s ease;
}

.card-link.primary {
    color: var(--color-primary);
    border-color: rgba(56, 189, 248, 0.3);
}

.card-link.primary:hover {
    border-color: var(--color-primary);
}

.card-link.secondary {
    color: var(--color-secondary-container);
    border-color: rgba(168, 85, 247, 0.3);
}

.card-link.secondary:hover {
    border-color: var(--color-secondary-container);
}

.card-link-text {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    font-weight: bold;
}

.card-link-icon {
    margin-left: 0.75rem;
    font-size: 0.875rem;
    transition: transform 0.3s ease;
}

.card-link:hover .card-link-icon {
    transform: translateX(0.5rem);
}

/* Engineering Card */
.eng-card {
    position: relative;
    width: 100%;
    background-color: var(--color-surface);
    border-radius: 1rem;
    overflow: hidden;
    border: 1px solid var(--border-medium);
    min-height: 380px;
    transition: all 0.5s ease;
    box-shadow: 0 0 1px 1px rgba(255, 255, 255, 0.1), 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    display: grid;
    grid-template-columns: 1fr;
}

@media (min-width: 768px) {
    .eng-card {
        grid-template-columns: 1fr 1fr;
    }
}

.eng-card:hover {
    box-shadow: 0 0 20px -5px rgba(255, 255, 255, 0.15);
}

.eng-content {
    position: relative;
    z-index: 20;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 1.5rem;
}

@media (min-width: 768px) {
    .eng-content {
        padding: 3.5rem;
    }
}

.eng-visual {
    position: relative;
    background-color: #000000;
    border-top: 1px solid var(--border-light);
    padding: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

@media (min-width: 768px) {
    .eng-visual {
        border-top: none;
        border-left: 1px solid var(--border-light);
        padding: 2rem;
    }
}

.eng-grid-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
    background: radial-gradient(#1A1A1A 1px, transparent 1px);
    background-size: 20px 20px;
    opacity: 0.4;
}

.eng-glow {
    position: absolute;
    width: 16rem;
    height: 16rem;
    background-color: rgba(168, 85, 247, 0.2);
    filter: blur(100px);
    border-radius: 50%;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.code-window {
    position: relative;
    width: 100%;
    max-width: 28rem;
    background-color: var(--color-surface-raised);
    border: 1px solid var(--border-light);
    border-radius: 0.75rem;
    padding: 1.25rem;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    transition: all 0.7s ease;
    box-shadow: 0 0 80px -20px rgba(168, 85, 247, 0.4);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

@media (min-width: 768px) {
    .code-window {
        padding: 2rem;
    }
}

.eng-card:hover .code-window {
    transform: rotate(-2deg) scale(1.05);
}

.code-block {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--color-text-muted);
    line-height: 1.625;
    white-space: pre;
}

@media (min-width: 768px) {
    .code-block {
        font-size: 0.875rem;
    }
}

.code-keyword {
    color: var(--color-secondary-container);
    font-weight: bold;
}

.code-type {
    color: var(--color-primary);
    font-weight: bold;
}

.code-string {
    color: var(--color-secondary-container);
}

.code-function {
    color: var(--color-secondary-container);
    font-style: italic;
}

/* Footer */
.footer {
    width: 100%;
    border-top: 1px solid var(--border-light);
    padding: 1.5rem 1.5rem;
    background-color: #000000;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
}

@media (min-width: 768px) {
    .footer {
        flex-direction: row;
        padding: 4rem 3rem;
    }
}

.footer-brand {
    font-family: var(--font-editorial);
    font-size: 1.5rem;
    color: #ffffff;
    font-style: italic;
}

.footer-copy {
    font-family: var(--font-mono);
    font-size: 0.625rem;
    letter-spacing: 0.1em;
    color: var(--color-text-dark);
    text-transform: uppercase;
}

.footer-links {
    display: flex;
    gap: 2rem;
}

.footer-link {
    font-family: var(--font-mono);
    font-size: 0.625rem;
    color: var(--color-text-dark);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    transition: color 0.3s ease;
}

.footer-link:hover {
    color: #ffffff;
}

/* --- Scroll Animations --- */
.scroll-reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: opacity, transform;
}

.scroll-reveal.active {
    opacity: 1;
    transform: translateY(0);
}

.delay-100 {
    transition-delay: 100ms;
}

.delay-200 {
    transition-delay: 200ms;
}

.delay-300 {
    transition-delay: 300ms;
}

/* --- Skeleton Loader --- */
.skeleton-wrapper {
    position: fixed;
    inset: 0;
    background-color: var(--color-background);
    z-index: 100;
    overflow-y: hidden;
    transition: opacity 0.6s ease, visibility 0.6s ease;
}

.skeleton-wrapper.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.skeleton-block {
    background: linear-gradient(90deg, #0e0e0e 25%, #1a1a1a 50%, #0e0e0e 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite linear;
    border-radius: 0.25rem;
}

@keyframes shimmer {
    0% {
        background-position: 200% 0;
    }

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

.sk-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 1.5rem;
    border-bottom: 1px solid var(--border-light);
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(12px);
    z-index: 101;
}

@media (min-width: 768px) {
    .sk-nav {
        padding: 0 3rem;
    }
}

.sk-brand {
    width: 150px;
    height: 1.5rem;
}

.sk-langs {
    width: 80px;
    height: 1.25rem;
}

.sk-main {
    padding-top: 5rem;
    max-width: 1600px;
    margin: 0 auto;
}

.sk-hero {
    padding: 4rem 1.5rem;
    max-width: 100rem;
    margin: 0 auto;
}

@media (min-width: 768px) {
    .sk-hero {
        padding: 8rem 3rem;
    }
}

@media (min-width: 1024px) {
    .sk-hero {
        padding: 11rem 3rem;
    }
}

.sk-title {
    width: 70%;
    height: 3rem;
    margin-bottom: 1rem;
    border-radius: 0.5rem;
}

.sk-title-2 {
    width: 50%;
    height: 3rem;
    margin-bottom: 2rem;
    border-radius: 0.5rem;
}

@media (min-width: 768px) {

    .sk-title,
    .sk-title-2 {
        height: 5.5rem;
    }
}

.sk-subtitle {
    width: 100%;
    height: 1rem;
    margin-bottom: 0.75rem;
    max-width: 42rem;
}

.sk-subtitle-2 {
    width: 80%;
    height: 1rem;
    margin-bottom: 0.75rem;
    max-width: 42rem;
}

.sk-cards {
    padding: 0 1.5rem 4rem;
    max-width: 100rem;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

@media (min-width: 768px) {
    .sk-cards {
        padding: 0 3rem 8rem;
        gap: 4rem;
    }
}

.sk-card-1 {
    width: 100%;
    min-height: 380px;
    border-radius: 1rem;
    border: 1px solid var(--border-medium);
}

@media (min-width: 768px) {
    .sk-card-1 {
        min-height: 450px;
    }
}

.sk-card-2 {
    width: 100%;
    min-height: 380px;
    border-radius: 1rem;
    border: 1px solid var(--border-medium);
}