/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: #ffffff;
    /* Clean white background */
    color: #111;
    font-family: 'Inter', sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
}


/* Interactive Background Dots */
#background-dots {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}



/* Disable pointer events on the container so the canvas behind gets clicks for drawing,
   but re-enable on specific interactive elements */
.pointer-events-none {
    pointer-events: none;
}

.pointer-events-auto {
    pointer-events: auto;
}

/* Layout Container */
.container {
    max-width: 100%;
    margin: 0 auto;
    padding: 40px 48px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    position: relative;
    z-index: 10;
    /* Cleanly above the background canvas */
}

/* Header */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: auto;
    /* Pushes the rest of the content down */
    position: relative;
    z-index: 100;
}

.logo {
    font-size: 20px;
    font-weight: 800;
    letter-spacing: -0.5px;
    display: flex;
    align-items: center;
    cursor: default;
}

.logo-rest {
    display: inline-block;
    max-width: 0;
    overflow: hidden;
    transition: max-width 0.4s ease;
    vertical-align: bottom;
}

.logo:hover .logo-rest {
    max-width: 32px;
    /* Expanding to show "as" */
}



.theme-switch {
    background: none;
    border: none;
    cursor: pointer;
    color: #111;
    padding: 8px 12px;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 10px;
}

.toggle-text {
    font-size: 13px;
    font-weight: 500;
    letter-spacing: -0.01em;
    text-transform: uppercase;
    opacity: 0.8;
    transition: opacity 0.2s;
}

.theme-switch:hover {
    transform: scale(1.05);
}

.theme-switch:hover .toggle-text {
    opacity: 1;
}

.theme-switch:hover svg {
    transform: rotate(15deg);
}

.theme-switch svg {
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@media (max-width: 480px) {
    .toggle-text {
        display: none;
    }
}

/* Red-hot Micro-interactions */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

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

.modal-feature-block {
    opacity: 0;
    animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* Indie Projects Section */
.indie-projects {
    max-width: 900px;
    margin: 48px auto 80px auto;
    width: 100%;
    z-index: 10;
    position: relative;
}

.indie-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px;
}

.indie-intro {
    text-align: center;
    margin-bottom: 48px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.indie-title {
    font-size: 32px;
    font-weight: 800;
    letter-spacing: -0.04em;
    margin-bottom: 8px;
    color: #111;
}

.indie-subtitle {
    font-size: 16px;
    color: #555;
    line-height: 1.5;
}

.browser-mockup {
    display: flex;
    flex-direction: column;
    background: #ffffff;
    border: 1px solid #eaeaea;
    border-radius: 12px;
    overflow: hidden;
    text-decoration: none;
    color: inherit;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.04);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.browser-mockup:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.08);
}

.browser-header {
    display: flex;
    align-items: center;
    padding: 12px 16px;
    background: #f8f9fa;
    border-bottom: 1px solid #eaeaea;
    gap: 16px;
}

.browser-dots {
    display: flex;
    gap: 6px;
}

.browser-dots span {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.browser-dots span:nth-child(1) {
    background: #ff5f56;
}

.browser-dots span:nth-child(2) {
    background: #ffbd2e;
}

.browser-dots span:nth-child(3) {
    background: #27c93f;
}

.browser-address-bar {
    flex-grow: 1;
    background: #fff;
    padding: 6px 16px;
    border-radius: 6px;
    border: 1px solid #eaeaea;
    font-size: 11px;
    color: #666;
    text-align: center;
    font-family: monospace;
}

.browser-content {
    background: #fafafa;
    height: 320px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.browser-content img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
}

.placeholder-content p {
    font-size: 14px;
}

/* PROJECT SPECIFIC THEMES FOR MOCKUPS */

/* Valideaaa: Strategic, Dark, Technical */
.valideaaa-theme {
    background: #0a0a0c !important;
    display: flex;
    flex-direction: column;
    padding: 32px;
    align-items: flex-start !important;
    justify-content: flex-start !important;
    color: #fff;
    font-family: 'Inter', sans-serif;
}

.valideaaa-theme .v-tag {
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: #6366f1;
    margin-bottom: 12px;
    font-weight: 700;
}

.valideaaa-theme h2 {
    font-size: 24px !important;
    font-weight: 800 !important;
    color: #fff !important;
    text-align: left !important;
    line-height: 1.1;
    margin-bottom: 16px;
    letter-spacing: -0.03em;
}

.valideaaa-theme .v-stats {
    display: flex;
    gap: 12px;
    margin-top: auto;
    width: 100%;
}

.valideaaa-theme .v-stat-card {
    flex: 1;
    background: #16161a;
    border: 1px solid #222;
    padding: 12px;
    border-radius: 8px;
}

.valideaaa-theme .v-stat-label {
    font-size: 9px;
    color: #888;
    margin-bottom: 4px;
}

.valideaaa-theme .v-stat-value {
    font-size: 14px;
    font-weight: 700;
}

/* Feeduix: Clean, Minimalist, High-Contrast */
.feeduix-theme {
    background: #fafafa !important;
    display: flex;
    flex-direction: column;
    padding: 32px;
    align-items: center !important;
    justify-content: flex-start !important;
    font-family: 'Outfit', sans-serif;
    color: #111827;
}

.feeduix-theme .f-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 24px;
    align-self: flex-start;
}

.feeduix-theme .f-logo span {
    font-weight: 800;
    font-size: 14px;
    letter-spacing: -0.02em;
}

.feeduix-theme h2 {
    font-size: 24px !important;
    font-weight: 800 !important;
    color: #111827 !important;
    text-align: center !important;
    line-height: 1.1 !important;
    margin-bottom: 12px;
    letter-spacing: -0.04em !important;
    max-width: 240px;
}

.feeduix-theme h2 span {
    color: #ef4444;
}

.feeduix-theme p {
    font-size: 11px !important;
    color: #4b5563 !important;
    max-width: 240px;
    margin-bottom: 16px !important;
    line-height: 1.4;
    text-align: center;
}

.feeduix-theme .f-pills {
    display: flex;
    gap: 6px;
    margin-bottom: 20px;
}

.feeduix-theme .f-pills span {
    font-size: 8px;
    font-weight: 600;
    padding: 4px 10px;
    background: rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 99px;
    color: #4b5563;
}

.feeduix-theme .f-action-card {
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 12px;
    width: 100%;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.feeduix-theme .f-tabs {
    display: flex;
    background: rgba(0, 0, 0, 0.04);
    padding: 4px;
    border-radius: 8px;
    gap: 4px;
}

.feeduix-theme .f-tab {
    flex: 1;
    font-size: 9px;
    font-weight: 600;
    text-align: center;
    padding: 6px;
    border-radius: 6px;
    color: #6b7280;
}

.feeduix-theme .f-tab.active {
    background: #fff;
    color: #111827;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.feeduix-theme .f-input-mock {
    background: rgba(0, 0, 0, 0.04);
    border-radius: 8px;
    padding: 10px 12px;
    font-size: 10px;
    color: #9ca3af;
    text-align: left;
}

/* Visibility State Toggles */
.main-content,
.footer,
.sticky-notes-wrapper {
    transition: opacity 0.4s ease, transform 0.4s ease, filter 0.4s ease;
}

/* Generic hidden state - uses opacity/visibility so modals can animate */
.content-hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none !important;
}

/* Main page sections get hard-hidden so they don't block interactions */
.main-content.content-hidden,
.footer.content-hidden,
.sticky-notes-wrapper.content-hidden {
    display: none !important;
}

.indie-projects {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    max-width: 900px;
    width: 100%;
    z-index: 1000;
    /* High priority */
    transition: opacity 0.4s ease, transform 0.4s ease;
}

.indie-projects.indie-projects-hidden {
    display: none !important;
    visibility: hidden;
    pointer-events: none !important;
}

/* Bio Section centered vertically */
.bio-section {
    max-width: 100%;
    /* Take full width so notes can hang right */
    margin-top: auto;
    margin-bottom: 32px;
    display: flex;
    position: relative;
}

/* Important: Allow cursor to still look like a pencil when hovering over the text but NOT blocking the canvas behind it */
.bio-title {
    font-size: 28px;
    line-height: 1.4;
    font-weight: 700;
    letter-spacing: -0.5px;
    color: #000;
    max-width: 760px;
    /* Constrain text so notes don't overlap */
}

/* Sticky Notes */
.sticky-notes-wrapper {
    position: absolute;
    right: 48px;
    top: -40px;
    /* Peek out enough above the usecases grid to easily hover */
    display: flex;
    pointer-events: auto;
    z-index: 10;
    /* Keep underneath grid */
}

/* Global Tooltip for Sticky Notes */
.global-tooltip {
    position: absolute;
    background-color: #111;
    color: #fff;
    font-size: 13px;
    padding: 6px 14px;
    border-radius: 8px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease, transform 0.2s ease;
    transform: translateX(-50%) translateY(10px);
    font-weight: 500;
    font-family: 'Inter', sans-serif;
    z-index: 9999;
    /* Highest priority so it never gets hidden */
}

.global-tooltip.visible {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.sticky-note {
    width: 220px;
    /* Made smaller */
    padding: 20px 24px;
    box-shadow: 2px 4px 12px rgba(0, 0, 0, 0.1);
    font-family: 'Inter', sans-serif;
    font-size: 13px;
    /* Smaller text */
    line-height: 1.4;
    color: #111;
    position: relative;
    transition: transform 0.2s, box-shadow 0.2s, opacity 0.3s ease;
    cursor: grab;
    user-select: none;
    /* Prevent text selection while dragging */
}

.sticky-note.content-hidden {
    opacity: 0;
    pointer-events: none !important;
}

/* Actively dragged note */
.sticky-note.dragging {
    cursor: grabbing !important;
    z-index: 100 !important;
    box-shadow: 10px 15px 30px rgba(0, 0, 0, 0.2);
    transform: scale(1.05) rotate(0deg) !important;
}

.sticky-note a {
    color: inherit;
    text-decoration: underline;
    font-weight: 600;
}

.sticky-note:hover {
    transform: scale(1.05) rotate(0deg) !important;
    /* Removed z-index: 10 !important; which caused dragging to break over the grid */
}

.sticky-note strong {
    font-size: 14px;
    /* Scaled down slightly */
    display: block;
    margin-bottom: 8px;
}

.sticky-note ol {
    padding-left: 16px;
    margin: 0;
}

/* The thumbtack illusion */
.sticky-note::before {
    content: '';
    position: absolute;
    top: 6px;
    left: 50%;
    transform: translateX(-50%);
    width: 6px;
    height: 6px;
    background: #444;
    border-radius: 50%;
    box-shadow: 0 2px 2px rgba(0, 0, 0, 0.3);
}

.note-yellow {
    background: #fdf57d;
    transform: rotate(-3deg);
    z-index: 2;
}

.note-green {
    background: #bbf793;
    transform: rotate(5deg);
    margin-left: -20px;
    margin-top: 20px;
    z-index: 1;
}

.note-blue {
    background: #ade1ff;
    transform: rotate(-2deg);
    margin-left: -20px;
    margin-top: 40px;
    z-index: 0;
}

/* Selected Works Section */
.works-section {
    width: 100%;
    margin-bottom: 32px;
    position: relative;
    z-index: 20;
    /* Creates stacking context higher than the resting sticky notes */
}

.section-label {
    font-size: 13px;
    color: #666;
    margin-bottom: 16px;
    font-weight: 400;
}

/* Grid Layout for Use Cases */
.use-cases-grid {
    display: grid;
    /* Creating a 6-column grid so we can span columns to perfectly center 2 items below 3 */
    grid-template-columns: repeat(6, 1fr);
    gap: 0;
    position: relative;
    z-index: 20;
    /* High z-index to fully cover the resting sticky notes behind it */
}

/* Individual Card */
.use-case-card {
    padding: 24px 32px;
    border: 1px solid #d0d0d0;
    background-color: #fff;
    cursor: auto;
    position: relative;
    transition: border-radius 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
    border-radius: 0px;
    /* Start round */
    margin: -1px 0 0 -1px;
    /* Overlap borders elegantly */
    grid-column: span 2;
    /* Default spans 2 out of 6 (3 in a row) */
}

/* Make bottom 2 items span wider to center gracefully */
.use-case-card.span-col {
    grid-column: span 3;
    /* Spans 3 out of 6 (2 in a row) */
}

.use-case-card h3 {
    font-size: 16px;
    font-weight: 700;
    margin: 0 0 8px 0;
    color: #333;
}

.use-case-card p {
    margin: 0 0 16px 0;
    font-size: 14px;
    font-weight: 400;
    color: #444;
}

.use-case-card .label {
    display: block;
    font-size: 12px;
    color: #666;
}

/* MICRO-INTERACTIONS */

/* Individual Card Hover */
.use-case-card:hover {
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.06);
    z-index: 10;
    border-color: #999;
}

/* Drag State for SortableJS */
.use-case-card:active {
    cursor: grabbing;
}

.sortable-ghost {
    opacity: 0.2;
    background-color: #f0f0f0;
}

.sortable-drag {
    cursor: grabbing !important;
    background-color: #fff !important;
    box-shadow: 15px 15px 40px rgba(0, 0, 0, 0.1);
    z-index: 99 !important;
}

/* Footer Section */
.footer {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    /* When UI is hidden, we need to ensure the footer stays visible and anchored.
       It will be moved outside of .main-content in HTML to preserve it. */
    width: 100%;
    pointer-events: auto; /* Re-enable for mobile footer links */
}

/* Social Links */
.social-links {
    display: flex;
    gap: 12px;
    align-items: center;
}

.social-icon {
    text-decoration: none;
    transition: transform 0.2s ease, opacity 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.social-icon:hover {
    transform: translateY(-4px);
    opacity: 0.8;
}

/* Contact Wrap & Copy Tooltip */
.contact-wrap {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.copy-tooltip {
    position: absolute;
    top: -30px;
    right: 0;
    background: #111;
    color: #fff;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 500;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transform: translateY(5px);
    transition: all 0.2s ease;
    pointer-events: none;
}

.copy-tooltip.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.contact-link {
    font-size: 13px;
    color: #666;
    text-decoration: none;
    transition: color 0.2s ease;
}

.contact-link:hover {
    color: #111;
    text-decoration: underline;
}

/* Magnetic Interaction Transition */
.social-icon,
.theme-switch {
    transition: transform 0.15s ease-out, opacity 0.2s ease;
}

.use-case-card {
    transition: transform 0.2s ease-out, box-shadow 0.2s ease;
    will-change: transform;
}

/* 
=============================
 USE CASE MODAL
============================= 
*/
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 2000;
    display: flex;
    align-items: flex-end;
    /* Align modal content to bottom */
    transition: opacity 0.4s ease, visibility 0.4s ease;
    visibility: visible;
    opacity: 1;
}

.modal-overlay.content-hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

/* Slide up from bottom */
.modal-content {
    width: 100%;
    height: 90vh;
    background-color: #ffffff;
    border-radius: 24px 24px 0 0;
    box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.1);
    padding: 64px 48px 0 48px;
    position: relative;
    transform: translateY(0);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.modal-overlay.content-hidden .modal-content {
    transform: translateY(100%);
}

.modal-close {
    position: absolute;
    top: 32px;
    right: 48px;
    background: none;
    border: none;
    cursor: pointer;
    color: #111;
    padding: 8px;
    transition: transform 0.2s;
    background-color: #f5f5f5;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    transform: rotate(90deg);
    background-color: #e5e5e5;
}

.modal-body {
    width: 100%;
    overflow-y: auto;
    overflow-x: hidden;
    height: 100%;
    padding-bottom: 64px;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.modal-body::-webkit-scrollbar {
    display: none;
}

.modal-body h2 {
    max-width: 900px;
    margin: 0 auto 24px auto;
    font-size: 32px;
    font-weight: 700;
    letter-spacing: -0.5px;
    color: #111;
}

.modal-desc {
    max-width: 900px;
    margin: 0 auto 24px auto;
    font-size: 16px;
    line-height: 1.6;
    color: #444;
}

.modal-project-link-wrap {
    max-width: 900px;
    margin: 16px auto 0 auto;
    width: 100%;
}

.modal-project-link {
    display: inline-block;
    max-width: fit-content;
    padding: 8px 20px;
    font-size: 13px;
    font-weight: 400;
    color: #666;
    text-decoration: none;
    border: 1px solid #ddd;
    border-radius: 999px;
    /* Full pill shape */
    transition: all 0.2s ease;
    background-color: transparent;
}

.modal-project-link:hover {
    background-color: #f8f8f8;
    color: #111;
    border-color: #bbb;
}

.modal-gallery-header {
    max-width: 900px;
    margin: 32px auto 16px auto;
    /* Centered margin to align with text */
    font-size: 14px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #888;
    display: flex;
    align-items: center;
}

.gallery-scroll-hint {
    margin-left: 8px;
    font-size: 12px;
    text-transform: none;
    font-style: italic;
    font-weight: 400;
    color: #bbb;
    letter-spacing: 0;
}

/* Vertical Case Study Layout */
.modal-gallery {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 100px;
    /* Generous spacing for distinct feature storytelling */
    margin: 64px auto 0 auto;
    padding: 0 0 100px 0;
    width: 100%;
    max-width: 900px;
    overflow-x: hidden;
    overflow-y: visible;
}

.modal-feature-block {
    display: flex;
    flex-direction: column;
    width: 100%;
    gap: 32px;
}

.modal-gallery-item {
    width: 100%;
    height: auto;
    flex-shrink: 0;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.1);
    background-color: #f8f8f8;
    border: 1px solid #f0f0f0;
}

.modal-gallery-item img {
    width: 100%;
    height: auto;
    display: block;
    image-rendering: -webkit-optimize-contrast;
    transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

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

.feature-text-wrapper {
    max-width: 800px;
}

.feature-block-title {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 16px;
    color: #111;
    letter-spacing: -0.02em;
}

.feature-block-desc {
    font-size: 16px;
    line-height: 1.7;
    color: #555;
}

.gallery-placeholder {
    width: 100%;
    height: 300px;
    background-color: #f0f0f0;
    border: 1px dashed #ccc;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #888;
    font-weight: 500;
}

.gallery-placeholder {
    min-width: 400px;
    height: 300px;
    background-color: #f0f0f0;
    border: 1px dashed #ccc;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #888;
    font-weight: 500;
    flex-shrink: 0;
}

/* Responsive adjustments */
/* Responsive adjustments */
@media (max-width: 1024px) {
    .container {
        padding: 40px;
    }

    .use-cases-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .use-case-card,
    .use-case-card.span-col {
        grid-column: span 1 !important;
    }

    .indie-projects {
        max-width: 90% !important;
    }

    .sticky-notes-wrapper {
        display: none !important;
        /* Hide earlier to prevent clutter at 1024px */
    }
}

@media (max-width: 768px) {
    .container {
        padding: 32px 24px;
    }

    .use-cases-grid,
    .indie-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .bio-title {
        font-size: 24px;
        line-height: 1.3;
    }

    /* Refactor Indie Projects Overlay for Mobile (Tablet/Phone) */
    .indie-projects {
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        right: 0 !important;
        bottom: 0 !important;
        width: 100% !important;
        height: 100% !important;
        max-width: 100% !important;
        transform: none !important;
        padding: 120px 24px 40px 24px;
        /* Space for the fixed header */
        background: #fff;
        overflow-y: auto;
        z-index: 1000;
        visibility: visible;
        opacity: 1;
    }

    .indie-projects.indie-projects-hidden {
        transform: translateY(20px) !important;
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
    }

    .indie-intro {
        margin-bottom: 32px;
        text-align: left;
    }

    .indie-title {
        font-size: 28px;
    }

    .browser-content {
        height: 280px;
        /* Shorter for mobile */
    }

    .footer {
        flex-direction: column;
        align-items: flex-start;
        gap: 24px;
        padding-bottom: 40px;
    }

    /* Modal adjustments */
    .modal-close {
        top: 24px;
        right: 24px;
    }

    .modal-gallery-item {
        height: 400px;
    }

    .modal-gallery {
        margin: 48px 0 0 0;
        padding: 0 0 48px 0;
        width: 100%;
        gap: 64px;
    }

    .feature-block-title {
        font-size: 18px;
    }

    .feature-block-desc {
        font-size: 14px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 120px 16px 24px 16px; /* Increased top padding to account for fixed header */
    }

    .header {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        padding: calc(16px + env(safe-area-inset-top)) 16px 16px 16px;
        background: rgba(255, 255, 255, 0.85);
        backdrop-filter: blur(8px);
        -webkit-backdrop-filter: blur(8px);
        border-bottom: 1px solid rgba(0, 0, 0, 0.05);
        z-index: 3000; /* Topmost element */
    }

    .bio-title {
        font-size: 20px;
        font-weight: 700;
    }

    .section-label {
        font-size: 11px;
    }

    .use-case-card h3 {
        font-size: 18px;
    }

    .browser-content {
        height: 240px;
    }

    /* Adjust Browser Window specifically for small phones */
    .valideaaa-theme {
        padding: 20px;
    }

    .valideaaa-theme h2 {
        font-size: 18px !important;
    }

    .feeduix-theme {
        padding: 24px;
    }

    .feeduix-theme h2 {
        font-size: 20px !important;
    }

    .modal-body h2 {
        font-size: 24px;
    }

    .modal-gallery-item {
        height: 300px;
    }
}

/* Modal Section Headers (Process / Final Design) */
.modal-section-header {
    margin-top: 64px;
    margin-bottom: 24px;
    font-size: 13px;
    font-weight: 600;
    color: #999;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    border-top: 1px solid #eee;
    padding-top: 48px;
    text-align: left;
    align-self: stretch; /* Override parent align-items: center */
}

/* Other Designs Section Styles */
.other-design-header {
    margin-top: 64px;
    margin-bottom: 24px;
    font-size: 18px;
    font-weight: 700;
    color: #111;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    border-top: 1px solid #eee;
    padding-top: 48px;
}

.modal-other-designs-grid {
    display: flex;
    flex-direction: column;
    gap: 48px;
    margin-bottom: 64px;
}

.other-design-item {
    background: #fcfcfc;
    border: 1px solid #eee;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    width: 100%;
}

.other-design-item:hover {
    transform: translateY(-8px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    border-color: #ddd;
}

.other-design-item img {
    width: 100%;
    height: auto;
    display: block;
}

.other-design-caption {
    padding: 16px;
    font-size: 13px;
    color: #666;
    background: #fff;
    border-top: 1px solid #eee;
    font-family: 'Inter', sans-serif;
}

@media (max-width: 768px) {
    .modal-other-designs-grid {
        grid-template-columns: 1fr;
    }
}