/*
  mobile.css
  Loaded after styles.css.

  This file only contains mobile/tablet overrides.
  It reuses the same CSS variables from styles.css, so major theme changes
  such as colors, spacing tokens, shadows, and border styles carry across both.
*/

@media (max-width: 980px) {
    body {
        overflow-x: hidden;
    }

    body.cursor-enabled,
    body.cursor-enabled a,
    body.cursor-enabled button,
    body.cursor-enabled .project-card,
    body.cursor-enabled .skill-bubble,
    body.cursor-enabled .contact-pill {
        cursor: auto;
    }

    .custom-cursor {
        display: none;
    }

    .container,
    .navbar {
        width: min(100% - 28px, var(--max-width));
    }

    .hero {
        min-height: auto;
        padding: 54px 0 44px;
    }

    .hero-grid,
    .resume-grid,
    .contact-layout {
        grid-template-columns: 1fr;
    }

    .side-panel {
        padding: 16px;
    }

    .projects-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .contact-layout {
        gap: 24px;
    }
}

@media (max-width: 760px) {
    .navbar {
        top: 10px;
        margin-top: 10px;
        padding: 10px;
        border-radius: 22px;
    }

    .brand {
        max-width: calc(100% - 58px);
    }

    .brand span:last-child {
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .brand-mark {
        flex: 0 0 auto;
        width: 36px;
        height: 36px;
        font-size: 0.72rem;
    }

    .menu-button {
        display: grid;
        place-items: center;
        flex: 0 0 auto;
    }

    .nav-links {
        position: absolute;
        top: calc(100% + 10px);
        left: 0;
        right: 0;
        display: none;
        flex-direction: column;
        align-items: stretch;
        gap: 6px;
        padding: 12px;
        border: 1px solid var(--border);
        border-radius: 20px;
        background: rgba(11, 15, 23, 0.97);
        backdrop-filter: blur(18px);
        -webkit-backdrop-filter: blur(18px);
        box-shadow: var(--shadow);
    }

    .nav-links.open {
        display: flex;
    }

    .nav-links a {
        width: 100%;
        min-height: 46px;
        justify-content: center;
    }

    section {
        scroll-margin-top: 96px;
    }

    .hero {
        padding: 42px 0 34px;
    }

    .hero-copy {
        min-height: auto;
        padding: 30px 22px;
        border-radius: 24px;
    }

    .hero-copy::after,
    .contact-card::after {
        opacity: 0.72;
        width: 200px;
        height: 200px;
    }

    .eyebrow {
        margin-bottom: 18px;
        font-size: 0.74rem;
        letter-spacing: 0.06em;
    }

    h1 {
        margin-bottom: 18px;
        font-size: clamp(2.55rem, 13vw, 4.25rem);
        line-height: 0.98;
        letter-spacing: -0.065em;
    }

    .hero-description {
        margin-bottom: 24px;
        font-size: 1rem;
        line-height: 1.65;
    }

    .button-row,
    .project-card .button-row {
        flex-direction: column;
        gap: 10px;
    }

    .btn {
        width: 100%;
        min-height: 48px;
    }

    .mini-card,
    .resume-card,
    .project-card,
    .contact-card {
        border-radius: 22px;
    }

    .mini-card,
    .resume-card,
    .project-card {
        padding: 22px;
    }

    .section-block {
        padding: 44px 0;
    }

    .section-heading {
        align-items: flex-start;
        flex-direction: column;
        gap: 12px;
        margin-bottom: 20px;
    }

    .section-heading h2 {
        font-size: clamp(2rem, 10vw, 3rem);
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }

    .project-card {
        min-height: auto;
    }

    .project-card p {
        line-height: 1.65;
    }

    .skill-list {
        gap: 8px;
    }

    .skill-bubble {
        padding: 8px 11px;
        font-size: 0.82rem;
    }

    .contact-line {
        align-items: flex-start;
        flex-direction: column;
        gap: 6px;
    }

    .contact-layout {
        gap: 22px;
    }

    .contact-card {
        padding: 28px 22px;
    }

    .contact-card h3 {
        font-size: clamp(2rem, 11vw, 3rem);
    }

    .contact-card p {
        line-height: 1.65;
    }

    .contact-list {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 10px;
    }

    .contact-pill {
        min-height: 78px;
        padding: 14px;
        border-radius: 18px;
        transform: none;
    }

    .contact-pill:hover {
        transform: translateY(-3px);
    }

    .contact-icon {
        width: 30px;
        height: 30px;
    }

    footer {
        padding-bottom: 30px;
        font-size: 0.86rem;
    }
}

@media (max-width: 460px) {
    .container,
    .navbar {
        width: min(100% - 20px, var(--max-width));
    }

    .hero-copy,
    .mini-card,
    .resume-card,
    .project-card,
    .contact-card {
        padding: 20px;
    }

    .brand span:last-child {
        max-width: 190px;
    }

    h1 {
        font-size: clamp(2.3rem, 15vw, 3.4rem);
    }

    .hero-description,
    .section-heading p,
    .project-card p,
    .timeline-item p,
    .resume-card li,
    .contact-card p {
        font-size: 0.95rem;
    }

    .contact-list {
        grid-template-columns: 1fr;
    }

    .contact-pill {
        min-height: 64px;
    }
}
