@import url('https://fonts.googleapis.com/css2?family=Roboto+Mono:wght@300;400;500;600;700&display=swap');

body {
    margin: 0;
    padding: 0;
    font-family: 'Roboto Mono', monospace;
    background-color: #fff;
    overflow: hidden;
}

main {
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 95vh;
    transition: transform 0.5s;
    overflow: hidden;
}

.slide {
    position: absolute;
    top: 0;
    width: 100%;
    height: 100vh;
    text-align: left;
    padding: 0 10vw;
    box-sizing: border-box;
    transition: opacity 0.5s, transform 0.5s;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    opacity: 0;
    transform: translateY(100vh);
}

/* ID card slide — centered */
#about {
    align-items: center;
    text-align: center;
    padding: 0;
}

/* Contact slides — left-aligned, matches rest of site */
.contact-slide {
    padding: 0 10vw;
}

/* Mailing list — right-aligned for variety */
#mailing-list {
    align-items: flex-end;
    text-align: right;
}

#mailing-list .contact-form input[type="email"],
#mailing-list .contact-form button[type="submit"] {
    text-align: right;
}

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

.passed {
    opacity: 0;
    transform: translateY(-100vh);
}

h2 {
    font-size: 24px;
    margin-bottom: 0.5em;
}

@media screen and (min-width: 769px) {
    .left h2 {
        padding-right: 2em;
    }
}
h3 {
    margin-bottom: 3px;
}
img {
    width: 80%;
    height: 80%;
    max-width: 300px;
    max-height: 300px;
    object-fit: cover;
}
p {
    font-size: 16px;
    margin-top: 2px;
    margin-bottom: 2px;
}

/* ── Viewport-spanning slide typography ── */
#home h1 {
    font-size: clamp(28px, 5vw, 78px);
    font-weight: 700;
    line-height: 1.04;
    letter-spacing: -0.025em;
    margin: 0 0 0.6em 0;
}

#home p {
    font-size: clamp(11px, 1vw, 14px);
    letter-spacing: 0.12em;
    color: #555;
}

#intro h2 {
    font-size: clamp(30px, 8vw, 110px);
    line-height: 1.0;
    letter-spacing: -0.03em;
    margin-bottom: 0.2em;
}

#intro > p {
    font-size: clamp(13px, 1.2vw, 17px);
    color: #555;
    margin-top: 1.2em;
    letter-spacing: 0.04em;
}

#tech-abt p,
#interests-abt p {
    font-size: clamp(16px, 2.4vw, 38px);
    line-height: 1.3;
    margin: 0 0 0.12em 0;
    letter-spacing: -0.01em;
}

#tech-abt .tech-label,
#interests-abt .tech-label {
    font-size: clamp(9px, 0.9vw, 13px);
    letter-spacing: 0.2em;
    color: #999;
    text-transform: uppercase;
    margin: 0 0 0.6em 0;
}

#interests-abt {
    align-items: flex-end;
    text-align: right;
}

#interests-topic-carousel {
    position: relative;
    width: 100%;
    /* height managed by JS */
}

#interests-abt .topic-item {
    position: absolute;
    left: 0;
    right: 0;
    margin: 0;
    white-space: nowrap;
}

#tech-abt .abt-intro,
#interests-abt .abt-intro {
    font-size: clamp(10px, 1.3vw, 20px);
    color: #555;
    letter-spacing: 0.02em;
    margin: 0 0 0.5em 0;
}

#tech-abt .tech-divider-line {
    font-size: clamp(10px, 1vw, 15px);
    color: #ccc;
    margin: 0.3em 0;
    letter-spacing: 0.1em;
}

#tech-abt .tech-sub-links {
    font-size: clamp(12px, 1.2vw, 18px);
    color: #555;
    letter-spacing: 0.02em;
}

.bold {
    font-weight: bolder;
}

.tiny {
    font-size:10px;
}
.column {
    float: left;
    width: 16em;
}
.left {
    text-align: center; 
}
.right {
    text-align: left;
}

.row:after {
    content: "";
    display: table;
    clear: both;
}

footer{
    text-align: center;
    opacity: 50%;
    position: fixed;
    bottom: 0;
    width: 100%;
    background-color: rgba(255, 255, 255, 0.9);
    padding: 5px 0;
    z-index: 10;
}

image-gallery {
    position: relative;
    height: 280px;
    width: 100%;
    max-width: 240px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.gallery-container {
    position: relative;
    height: 280px;
    width: 200px;
    perspective: 1000px;
    overflow: hidden;
}

.gallery-item {
    position: absolute;
    width: 100%;
    height: 160px;
    transition: all 0.5s ease;
    cursor: pointer;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 3px 6px rgba(0,0,0,0.2);
    top: 50%;
    transform-origin: center center;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
}

.gallery-item.center {
    transform: translateY(-50%) scale(1);
    opacity: 1;
    z-index: 3;
}

.gallery-item.top {
    transform: translateY(-130%) scale(0.8);
    opacity: 0.6;
    z-index: 2;
}

.gallery-item.bottom {
    transform: translateY(30%) scale(0.8);
    opacity: 0.6;
    z-index: 2;
}

.gallery-item.hidden {
    transform: translateY(-210%) scale(0.6);
    opacity: 0;
    z-index: 1;
}

.gallery-item.hidden-bottom {
    transform: translateY(110%) scale(0.6);
    opacity: 0;
    z-index: 1;
}

.image-caption {
    position: absolute;
    bottom: -30px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0,0,0,0.7);
    color: white;
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 12px;
    white-space: nowrap;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.gallery-item.center .image-caption {
    opacity: 1;
}

.gallery-controls {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.gallery-btn {
    background: #333;
    color: white;
    border: none;
    padding: 8px 12px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 12px;
    transition: background 0.3s ease;
}

.gallery-btn:hover {
    background: #555;
}

/* Mobile responsiveness  */
@media screen and (max-width: 768px) {
    .row {
        display: flex;
        flex-direction: column;
        align-items: center;
        padding: 0 10px; 
        box-sizing: border-box;
    }
    
    .column {
        float: none;
        width: 100%;
        max-width: 400px;
        margin-bottom: 8px; 
    }
    
    .left, .right {
        text-align: center;
    }
    
    
    .slide {
        padding: 0 6vw;
    }

    #about {
        padding: 0;
    }

    .contact-slide {
        padding: 0 6vw;
    }

    h2 {
        font-size: 20px;
        margin-bottom: 0.2em;
        margin-top: 0.2em;     }

    h3 {
        margin-bottom: 1px;
        margin-top: 5px;
        font-size: 16px;
    }

    p {
        font-size: 14px;
        margin-top: 0px;
        margin-bottom: 0px;
        line-height: 1.2;
    }
    
    .image-gallery {
        height: 140px; 
        width: 100%;
        max-width: 100%; 
        display: flex;
        justify-content: center;
        align-items: center;
        margin-bottom: 5px; 
        margin-top: 5px; 
    }
    
    .gallery-container {
        width: 360px; 
        height: 125px;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    .gallery-item {
        height: 100px; 
        width: 85px; 
        left: 50%;
        top: 50%;
        transform-origin: center center;
    }
    
    .gallery-item.center {
        transform: translate(-50%, -50%) scale(1);
        opacity: 1;
        z-index: 3;
    }
    
    .gallery-item.top {
        transform: translate(-150%, -50%) scale(0.8);
        opacity: 0.6;
        z-index: 2;
    }

    .gallery-item.bottom {
        transform: translate(50%, -50%) scale(0.8);
        opacity: 0.6;
        z-index: 2;
    }
    
    .gallery-item.hidden {
        transform: translate(-250%, -50%) scale(0.6);
        opacity: 0;
        z-index: 1;
    }

    .gallery-item.hidden-bottom {
        transform: translate(150%, -50%) scale(0.6);
        opacity: 0;
        z-index: 1;
    }
}

/* Mobile Navigation Hints */
@media screen and (max-width: 768px) {
    .slide {
        height: calc(100vh - 60px); 
        top: 0;
    }
    .nav-hint {
        position: fixed;
        display: flex;
        align-items: center;
        gap: 10px;
        font-size: 14px;
        color: #333;
        z-index: 100;
        opacity: 0;
        transition: opacity 0.3s ease;
    }
    
    .nav-hint.visible {
        opacity: 1;
    }
    
    .nav-hint-down {
        bottom: 80px;
        right: 20px;
        flex-direction: row;
        animation: bounceDown 2s infinite;
    }
    
    .nav-hint-up {
        top: 20px;
        left: 20px;
        flex-direction: row;
        animation: bounceUp 2s infinite;
    }
    
    .arrow-icon {
        font-size: 24px;
    }
    
    @keyframes bounceDown {
        0%, 100% {
            transform: translateY(0);
        }
        50% {
            transform: translateY(10px);
        }
    }
    
    @keyframes bounceUp {
        0%, 100% {
            transform: translateY(0);
        }
        50% {
            transform: translateY(-10px);
        }
    }
}

/* Form Styles */
form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    max-width: 500px;
    margin: 0 auto;
    padding: 2rem;
    border: 2px solid #333;
    background-color: #fff;
}

label {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    font-family: 'Roboto Mono', monospace;
    font-size: 14px;
    font-weight: 500;
}

input[type="email"],
textarea {
    padding: 0.75rem;
    border: 2px solid #333;
    background-color: #fff;
    font-family: 'Roboto Mono', monospace;
    font-size: 14px;
    transition: all 0.3s ease;
    outline: none;
}

input[type="email"]:focus,
textarea:focus {
    border-color: #000;
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.1);
}

textarea {
    min-height: 150px;
    resize: vertical;
}

button[type="submit"] {
    padding: 0.75rem 1.5rem;
    border: 2px solid #333;
    background-color: #fff;
    color: #333;
    font-family: 'Roboto Mono', monospace;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}

button[type="submit"]:hover {
    background-color: #333;
    color: #fff;
}

button[type="submit"]:active {
    transform: scale(0.98);
}

/* Hover reveal effect - reusable */
.hover-reveal {
    display: inline-block;
    cursor: pointer;
    padding: 0.2em 0.4em;
    margin: -0.2em -0.4em;
    border-radius: 6px;
}

.hover-reveal .reveal-text {
    opacity: 0;
    max-height: 0;
    overflow: hidden;
    margin: 0;
    transition: opacity 0.3s ease, max-height 0.3s ease, margin-top 0.3s ease;
}

.hover-reveal:hover .reveal-text {
    opacity: 1;
    max-height: 4em;
    margin-top: 0.4em;
}

/* Project link with underline and fill effect */
.project-link {
    position: relative;
    background: linear-gradient(to top, #000 0%, #000 100%);
    background-size: 100% 0%;
    background-position: bottom;
    background-repeat: no-repeat;
    transition: background-size 0.3s ease, color 0.3s ease, text-decoration-color 0.3s ease;
    padding: 0 1px;
    color: inherit;
    text-decoration: underline;
    text-decoration-thickness: 2px;
    text-decoration-color: #000;
    text-underline-offset: 4px;
}

.project-link:hover {
    background-size: 100% 100%;
    color: #fff;
    text-decoration-color: transparent;
}

/* ===== DRIVER'S LICENSE ===== */

.dl-scene {
    perspective: 1400px;
    display: inline-block;
    cursor: pointer;
    user-select: none;
    -webkit-user-select: none;
}

.dl-card {
    width: 530px;
    height: 334px;
    position: relative;
    transform-style: preserve-3d;
    transition: transform 0.42s cubic-bezier(0.34, 1.2, 0.64, 1);
}

.dl-card.hovering:not(.held) {
    transform: translateY(-10px) scale(1.02);
}

/* .dl-card.held transform is managed entirely by JS (mouse-tracking tilt) */

.dl-card.flipped:not(.hovering):not(.held) {
    transform: rotateY(180deg);
}

.dl-card.flipped.hovering:not(.held) {
    transform: translateY(-10px) scale(1.02) rotateY(180deg);
}

/* .dl-card.flipped.held handled by JS */

.dl-card.flipping {
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.dl-face {
    position: absolute;
    inset: 0;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    border-radius: 10px;
    overflow: hidden;
    font-family: 'Roboto Mono', monospace;
    box-shadow: 0 2px 8px rgba(0,0,0,0.18);
    transition: box-shadow 0.35s ease;
}

.dl-scene.hovering .dl-face { box-shadow: 0 14px 32px rgba(0,0,0,0.30); }
.dl-scene.held .dl-face     { box-shadow: 0 30px 55px rgba(0,0,0,0.44); }

/* ---- FRONT ---- */
.dl-front {
    background: #fff;
    border: 1px solid #000;
    display: flex;
    flex-direction: column;
}

.dl-hdr {
    padding: 6px 14px 5px;
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    border-bottom: 1px solid #000;
    flex-shrink: 0;
}

.dl-hdr-state {
    color: #000;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.3em;
}

.dl-hdr-type {
    color: #555;
    font-size: 8px;
    letter-spacing: 0.2em;
}

.dl-body {
    flex: 1;
    display: flex;
    border-bottom: 1px solid #000;
    padding: 12px 14px;
    gap: 14px;
    align-items: flex-start;
    overflow: hidden;
    min-height: 0;
}

.dl-photo-col {
    flex-shrink: 0;
}

.dl-photo-wrap {
    border: 1px solid #000;
    overflow: hidden;
}

.dl-photo-wrap img {
    width: 148px;
    height: 188px;
    object-fit: cover;
    display: block;
    filter: grayscale(100%) contrast(1.1);
}

.dl-fields {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 6px;
    overflow: hidden;
    min-width: 0;
    text-align: left;
}

.dl-fields-lower {
    display: flex;
    flex-direction: row;
    flex: 1;
    gap: 10px;
    min-height: 0;
}

.dl-fields-main {
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-width: 56%;
}

.dl-fields-col2 {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-left: 10px;
    border-left: 1px solid #ddd;
}

.dl-alias {
    font-size: 7.5px;
    color: #888;
    letter-spacing: 0.02em;
}

.dl-fields-divider {
    height: 1px;
    background: #000;
    flex-shrink: 0;
    margin: 1px 0;
}

.dl-field-group {
    display: flex;
    flex-direction: column;
    gap: 1px;
}

.dl-field-row {
    display: flex;
    gap: 16px;
}

.dl-lbl {
    font-size: 6.5px;
    letter-spacing: 0.15em;
    color: #888;
    text-transform: uppercase;
}

.dl-val {
    font-size: 11.5px;
    color: #000;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.dl-val--name {
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.03em;
}

.dl-val--age {
    font-size: 8px;
    color: #333;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.dl-foot {
    padding: 4px 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-shrink: 0;
}

.dl-foot-num {
    font-size: 7px;
    letter-spacing: 0.1em;
    color: #888;
}

.dl-foot-meta {
    font-size: 7px;
    letter-spacing: 0.1em;
    color: #555;
}

/* ---- BACK ---- */
.dl-back {
    background: #fff;
    border: 1px solid #000;
    transform: rotateY(180deg);
    display: flex;
    align-items: center;
    justify-content: center;
}

.dl-social-list {
    width: 100%;
    height: 100%;
    padding: 0 28px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 18px;
}

.dl-social-item {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    width: fit-content;
    text-decoration: none;
    color: inherit;
    cursor: pointer;
}

.dl-social-icon {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    color: #000;
}

.dl-social-lbl {
    font-size: 7px;
    letter-spacing: 0.2em;
    color: #aaa;
    text-transform: uppercase;
    flex-shrink: 0;
}

.dl-social-handle {
    font-size: 14px;
    color: #000;
    letter-spacing: 0.01em;
    border-bottom: 1px solid #000;
    padding-bottom: 1px;
}

/* Driver's license mobile */
@media screen and (max-width: 580px) {
    .dl-card {
        width: calc(100vw - 36px);
        max-width: 340px;
        height: calc(min(100vw - 36px, 340px) * 0.63);
    }

    .dl-hdr-state       { font-size: 10px; letter-spacing: 0.22em; }
    .dl-hdr-type        { font-size: 5.5px; }
    .dl-body            { padding: 7px 8px; gap: 8px; }
    .dl-photo-wrap img  { width: 82px; height: 104px; }
    .dl-fields          { gap: 4px; }
    .dl-fields-divider  { margin: 1px 0; }
    .dl-lbl             { font-size: 5.5px; }
    .dl-val             { font-size: 8.5px; }
    .dl-val--name       { font-size: 9px; }
    .dl-val--age        { font-size: 6px; }
    .dl-alias           { font-size: 6px; }
    .dl-foot            { padding: 3px 9px; }
    .dl-foot-num        { font-size: 6px; }
    .dl-foot-meta       { font-size: 6px; }
    .dl-fields-lower    { gap: 7px; }
    .dl-fields-main     { gap: 4px; }
    .dl-fields-col2     { gap: 5px; padding-left: 7px; }
    .dl-social-list     { padding: 0 14px; gap: 12px; }
    .dl-social-icon     { width: 13px; height: 13px; }
    .dl-social-lbl      { font-size: 5.5px; }
    .dl-social-handle   { font-size: 10px; }
}

/* Name highlight with underline and fill effect */
.name-highlight {
    position: relative;
    background: linear-gradient(to top, #000 0%, #000 100%);
    background-size: 100% 0%;
    background-position: bottom;
    background-repeat: no-repeat;
    transition: background-size 0.3s ease, color 0.3s ease;
    padding: 0 4px;
    cursor: pointer;
}

.name-highlight::after {
    content: '';
    position: absolute;
    left: 4px;
    right: 4px;
    bottom: 0;
    height: 2px;
    background-color: #000;
}

.hover-reveal:hover .name-highlight {
    background-size: 100% 100%;
    color: #fff;
}

/* ===== CONTACT SECTIONS ===== */

.contact-heading {
    font-size: clamp(28px, 5vw, 72px);
    font-weight: 700;
    line-height: 1.04;
    letter-spacing: -0.025em;
    margin: 0.15em 0 0 0;
}

.contact-sub {
    font-size: clamp(11px, 1vw, 14px);
    letter-spacing: 0.06em;
    color: #555;
    margin-top: 0.6em;
    margin-bottom: 0;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 0;
    max-width: 480px;
    padding: 0;
    border: none;
    margin: 1.8em 0 0 0;
    background: transparent;
}

.contact-form textarea,
.contact-form input[type="email"] {
    border: none;
    border-bottom: 1px solid #000;
    padding: 0.5rem 0;
    background: transparent;
    font-family: 'Roboto Mono', monospace;
    font-size: clamp(13px, 1.2vw, 16px);
    outline: none;
    resize: none;
    min-height: 72px;
    color: #000;
    box-shadow: none;
    border-radius: 0;
    margin-bottom: 1.2rem;
}

.contact-form input[type="email"] {
    min-height: unset;
    height: auto;
}

.contact-form textarea::placeholder,
.contact-form input[type="email"]::placeholder {
    color: #bbb;
}

.contact-form button[type="submit"] {
    border: none;
    border-bottom: none;
    background: transparent;
    padding: 0;
    text-align: left;
    font-family: 'Roboto Mono', monospace;
    font-size: clamp(10px, 0.9vw, 13px);
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: #999;
    cursor: pointer;
    transition: color 0.2s ease;
    width: fit-content;
    transform: none;
}

.contact-form button[type="submit"]:hover {
    color: #000;
    background: transparent;
}

.contact-form button[type="submit"]:active {
    transform: none;
}

.contact-info-blocks {
    display: flex;
    flex-direction: column;
    gap: 1.8rem;
    margin-top: 1.8em;
}

.contact-info-block {
    display: flex;
    flex-direction: column;
    gap: 0.18em;
}

.contact-block-label {
    font-size: clamp(9px, 0.85vw, 12px);
    letter-spacing: 0.2em;
    color: #999;
    text-transform: uppercase;
    margin: 0 0 0.4em 0;
}

.contact-info-block p {
    font-size: clamp(13px, 1.4vw, 18px);
    margin: 0;
    color: #000;
    line-height: 1.5;
}

.contact-encoded-note {
    font-size: clamp(9px, 0.8vw, 11px) !important;
    color: #bbb !important;
    letter-spacing: 0.06em;
    margin-top: 0.3em !important;
}