/* Font stack aligned with Members and Human Practices pages */
@font-face {
    font-family: 'Blinker';
    src: url('https://static.igem.wiki/teams/5836/fonts/blinker/blinker-regular.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Raleway';
    src: url('https://static.igem.wiki/teams/5836/fonts/raleway/raleway-regular.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Nixie One';
    src: url('') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Fraunces';
    src: url('https://static.igem.wiki/teams/5836/fonts/fraunces/fraunces-72pt-regular.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

/* Override the global body padding and container for design page */
body {
    background-color: #0b1320 !important;
    padding-top: 0 !important; /* Remove the global 90px padding */
}

/* Make container full width and remove padding for design page */
.container {
    max-width: none !important;
    padding: 0 !important;
    margin: 0 !important;
    background-color: #0b1320 !important;
}

#page_content {
    background-color: #0b1320 !important;
}

.main-content,
.container-fluid,
main {
    background-color: #0b1320 !important;
}

/* Hero section */
.design-hero {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: min(calc(var(--vh, 1vh) * 72), 720px);
    padding: clamp(6rem, 12vw, 10rem) 1.5rem 4rem;
    padding-top: calc(90px + clamp(6rem, 12vw, 10rem)); /* Account for the fixed navbar */
    text-align: center;
    overflow: visible;
    isolation: isolate;
    box-sizing: border-box;
}

.design-hero__inner {
    max-width: min(60ch, 860px);
    z-index: 2;
}

.design-hero__title {
    font-family: 'Fraunces', serif;
    font-weight: bold; /* Changed from 800 to bold for better compatibility */
    font-size: clamp(3.5rem, 10vw, 6rem);
    letter-spacing: 0.05em;
    color: #d7af6b;
    margin: 0;
    text-shadow: 0 18px 36px rgba(0, 0, 0, 0.45);
    text-transform: uppercase;
}

.design-hero__ring {
    position: absolute;
    width: clamp(340px, 42vw, 540px);
    height: auto;
    pointer-events: none;
    opacity: 0.9;
    filter: drop-shadow(0 20px 38px rgba(0, 0, 0, 0.45));
    animation: design-hero-spin 26s linear infinite;
    z-index: 1;
}

.design-hero__ring--left {
    top: 41%;
    left: clamp(14vw, 18vw, 22vw);
}

.design-hero__ring--right {
    top: 19%;
    right: clamp(14vw, 18vw, 22vw);
    animation-direction: reverse;
}

@media (max-width: 600px) {
    .design-hero__ring {
        width: clamp(180px, 70vw, 320px);
    }

    .design-hero__ring--left {
        left: -10vw;
    }

    .design-hero__ring--right {
        right: -10vw;
    }
}

@keyframes design-hero-spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

/* Section Navigation */
.section-navigation {
    position: fixed;
    top: 100px;
    left: 20px;
    background: rgba(11, 19, 32, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    border: 1px solid rgba(215, 175, 107, 0.3);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    min-width: 180px;
    max-width: 250px;
    transition: all 0.3s ease;
    transform: scale(0.75);
    transform-origin: top left;
}

.navigation-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid rgba(215, 175, 107, 0.2);
    cursor: pointer;
}

.navigation-title {
    font-family: 'Fraunces', serif;
    font-size: 1.1rem;
    font-weight: 600;
    color: #d7af6b;
    letter-spacing: 0.5px;
}

.navigation-toggle {
    background: none;
    border: none;
    color: #d7af6b;
    cursor: pointer;
    padding: 0;
    display: none;
    transition: transform 0.3s ease;
}

.navigation-content {
    padding: 0.75rem 0;
    max-height: 400px;
    overflow-y: auto;
    transition: all 0.3s ease;
    /* Hide scrollbar */
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* Internet Explorer 10+ */
}

.navigation-content::-webkit-scrollbar {
    display: none; /* Safari and Chrome */
}

.navigation-item {
    display: block;
    padding: 0.6rem 1.25rem;
    color: #afc1d0;
    text-decoration: none;
    font-family: 'Nixie One', serif;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    border-left: 3px solid transparent;
    position: relative;
}

.navigation-item:hover {
    color: #d7af6b;
    background: rgba(215, 175, 107, 0.1);
    border-left-color: #d7af6b;
    text-decoration: none;
}

.navigation-item.active {
    color: #d7af6b;
    background: rgba(215, 175, 107, 0.15);
    border-left-color: #d7af6b;
    font-weight: 500;
}

@media (max-width: 1200px) and (min-width: 769px) {
    .section-navigation {
        transform: scale(0.65);
        min-width: 160px;
        max-width: 220px;
    }
}

@media (max-width: 768px) {
    .section-navigation {
        top: 85px;
        left: 0;
        right: 0;
        width: 100%;
        min-width: auto;
        max-width: none;
        border-radius: 0;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
        background-color: #0b1320;
        backdrop-filter: none;
        z-index: 49;
    }

    .navigation-toggle {
        display: block;
    }

    .navigation-content {
        display: none;
    }

    .navigation-content.active {
        display: block;
    }

    .navigation-toggle.active {
        transform: rotate(180deg);
    }
}

@media (max-width: 480px) {
    .section-navigation {
        top: 80px;
    }
}

@media (max-width: 360px) {
    .section-navigation {
        top: 75px;
    }
}

html.js-enabled .design-hero,
html.js-enabled .design-section {
    opacity: 0;
    transform: translate3d(0, 48px, 0);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

html.js-enabled .design-hero.is-visible,
html.js-enabled .design-section.is-visible {
    opacity: 1;
    transform: translate3d(0, 0, 0);
}

html.js-enabled .design-section.design-hairpin-init {
    opacity: 1;
    transform: none;
}

html.js-enabled .design-hero__inner {
    opacity: 0;
    transform: translate3d(0, 32px, 0);
    transition: opacity 0.9s ease, transform 0.9s ease;
}

html.js-enabled .design-hero.is-visible .design-hero__inner {
    opacity: 1;
    transform: translate3d(0, 0, 0);
}

html.js-enabled .design-hero__ring {
    opacity: 0;
    transition: opacity 1.2s ease;
}

html.js-enabled .design-hero.is-visible .design-hero__ring {
    opacity: 0.9;
}

@media (prefers-reduced-motion: reduce) {
    html.js-enabled .design-hero,
    html.js-enabled .design-section,
    html.js-enabled .design-hero__inner {
        transition: none;
        transform: none;
        opacity: 1;
    }
}

.design-section {
    position: relative;
    display: flex;
    justify-content: center;
    padding: clamp(0.5rem, 2vw, 1rem) 0; /* Further reduced padding */
}

.design-section__inner {
    width: 75%;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
    padding: 2rem;
    padding-left: 150px; /* Account for side navigation */
    display: flex;
    flex-direction: column;
    gap: clamp(0.25rem, 1vw, 0.75rem); /* Further reduced gap */
}

/* Mobile responsive adjustment */
@media (max-width: 768px) {
    .design-section__inner {
        width: 95%;
        padding-left: 1rem;
        padding-right: 1rem;
    }
}

.design-section__title, .section-title {
    font-family: 'Fraunces', serif;
    font-weight: bold;
    font-size: clamp(2rem, 4vw, 3.5rem); /* Same as model page */
    color: #d7af6b;
    margin: 0.5rem 0 0.25rem 0; /* Minimal margins */
    text-align: left;
    line-height: 1.2;
}

.design-workflow__figure {
    text-align: center;
    margin: 0.25rem 0; /* Minimal margins */
}

.design-workflow__image {
    width: 156% !important; /* 20% bigger than 130% (130% * 1.2 = 156%) */
    max-width: 100% !important; /* Ensure it doesn't overflow container */
    height: auto;
    border-radius: 0.8rem;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.1);
    display: block;
    margin: 0 auto;
    clip-path: inset(0 20% 0 20%); /* Crop 20% from left and right sides */
}

/* More specific selector for workflow image */
.design-workflow__figure .design-workflow__image,
.design-workflow__figure img.design-workflow__image {
    width: 156% !important; /* 20% bigger than 130% */
    max-width: 100% !important;
    clip-path: inset(0 20% 0 20%) !important; /* Crop 20% from left and right sides */
}

/* References styling - exact match to model.css */
.references-section {
    text-align: left;
    line-height: 1.8;
    font-size: clamp(1rem, 1.2vw, 1.2rem); /* Same as paragraph font size */
    font-family: 'Nixie One', serif !important;
}

.references-section p {
    margin-bottom: 1rem;
    font-family: 'Nixie One', serif !important;
    color: white !important;
    font-size: clamp(1rem, 1.2vw, 1.2rem) !important;
    line-height: 1.8 !important;
}

/* References List Styling - exact match to model.css */
.references-list {
    font-family: 'Nixie One', serif !important;
    font-size: clamp(1rem, 1.2vw, 1.2rem) !important;
    color: white !important;
    line-height: 1.8 !important;
    margin: 2rem 0 !important;
    padding-left: 2rem !important;
}

.references-list li {
    font-family: 'Nixie One', serif !important;
    font-size: clamp(1rem, 1.2vw, 1.2rem) !important;
    color: white !important;
    line-height: 1.8 !important;
    margin-bottom: 1rem;
}

/* Additional specificity for references - exact match to model.css */
ol.references-list,
ol.references-list li {
    font-family: 'Nixie One', serif !important;
    color: white !important;
}

/* Reference link colors - exact match to model.css */
.reference-link {
    color: #afc1d0 !important;
    text-decoration: underline !important;
}

.reference-link:hover {
    color: #d7af6b !important;
    text-decoration: underline !important;
}

/* Ensure reference links in references list use correct colors */
ol.references-list a.reference-link {
    color: #afc1d0 !important;
    text-decoration: underline !important;
}

ol.references-list a.reference-link:hover {
    color: #d7af6b !important;
    text-decoration: underline !important;
}

.design-crispr {
    padding-top: clamp(3rem, 8vw, 5rem);
    padding-bottom: clamp(3rem, 8vw, 5.5rem);
}

.design-crispr__eyebrow, .subsection-title {
    font-family: 'Fraunces', serif;
    font-weight: 600;
    font-size: clamp(1.5rem, 3vw, 2.5rem);
    color: #afc1d0;
    margin: 0.75rem 0 0.25rem 0; /* Minimal margins */
    text-align: left;
    line-height: 1.3;
}

.design-crispr__title {
    font-family: 'Fraunces', serif;
    font-weight: bold;
    font-size: clamp(2rem, 4vw, 3.5rem);
    color: #d7af6b;
    margin: 3rem 0 2rem 0;
    text-align: left;
    line-height: 1.2;
}

.design-crispr__copy, .paragraph {
    max-width: 100%;
    margin: 0.5rem 0; /* Minimal margins */
    font-family: 'Nixie One', serif;
    font-size: clamp(1.15rem, 1.45vw, 1.45rem);
    line-height: 1.6;
    color: #ffffff;
    text-align: left;
}

.design-crispr__copy {
    display: grid;
    gap: 0.2rem;
}

.design-crispr__copy em {
    font-style: italic;
}

.design-crispr__copy sup {
    font-size: 0.75em;
    vertical-align: super;
    margin-left: 0.1em;
}

.design-guidernas {
    padding-top: clamp(4rem, 9vw, 6.5rem);
    padding-bottom: clamp(4rem, 9vw, 6.75rem);
}

.design-guidernas__inner {
    max-width: min(1150px, 94vw);
    margin: 0 auto;
    text-align: left;
}

.design-guidernas__title {
    font-family: 'Fraunces', serif;
    font-weight: bold;
    font-size: clamp(2rem, 4vw, 3.5rem); /* Standardized to match other pages */
    color: #d7af6b;
    text-align: left;
    margin: 0.5rem 0 0.25rem 0; /* Minimal margin */
    text-shadow: 0 18px 36px rgba(0, 0, 0, 0.45);
}

.design-guidernas__lead,
.design-guidernas__body,
.design-guidernas__feature {
    font-family: 'Nixie One', serif;
    font-size: clamp(1.15rem, 1.45vw, 1.45rem);
    line-height: 1.6;
    color: #ffffff;
    margin: 1.5rem 0;
    text-align: left;
}

.design-guidernas__lead {
    max-width: 85ch;
    margin: 0 auto clamp(2.5rem, 6vw, 3.5rem);
    text-align: center;
}

.design-guidernas__list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: clamp(0.1rem, 0.2vw, 0.3rem);
}

.design-guidernas__item {
    display: grid;
    gap: clamp(0.1rem, 0.2vw, 0.2rem);
}


.design-guidernas__feature {
    margin: 0;
}

.design-guidernas__number {
    font-family: 'Nixie One', serif; /* Changed from cursive to serif */
    font-size: clamp(1.4rem, 3.2vw, 2rem);
    line-height: 1;
    color: #a3213b;
    display: inline-block;
    margin-right: 0.45rem;
    vertical-align: baseline;
}

.design-guidernas__feature strong {
    font-family: 'Fraunces', serif;
    font-weight: bold; /* Changed from 700 to bold */
    color: #ffffff;
}

.design-guidernas__tag {
    color: #ffffff;
}

.design-guidernas__sequence {
    position: relative;
    font-family: "Courier New", Courier, monospace;
    font-size: clamp(1.2rem, 2.7vw, 1.55rem);
    letter-spacing: 0.12em;
    color: #b1d4e0;
    background: none;
    border: none;
    padding: 0;
    text-align: center;
    word-break: break-word;
    cursor: text;
    user-select: text;
    -webkit-user-select: text;
}

.design-guidernas__sequence::after {
    content: attr(data-feedback);
    position: absolute;
    left: 50%;
    bottom: calc(-1 * clamp(2.5rem, 5vw, 3rem));
    transform: translate3d(-50%, 0, 0);
    opacity: 0;
    font-family: 'Blinker', sans-serif;
    font-size: clamp(0.75rem, 1.8vw, 0.95rem);
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #d7af6b;
    pointer-events: none;
    transition: none;
}

.design-guidernas__sequence[data-feedback]:not([data-feedback=""])::after {
    opacity: 1;
}

.design-guidernas__sequence--copied {
    color: #f4dca8;
    border-color: rgba(215, 175, 107, 0.55);
    box-shadow: 0 18px 34px rgba(16, 28, 46, 0.35);
}

.design-guidernas__figure {
    margin: 0;
    text-align: center;
    flex: 0 1 clamp(360px, 42vw, 520px);
}

.design-guidernas__figures {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
    margin: 1rem auto; /* Reduced margins */
    max-width: 100%;
    text-align: center;
}

.design-guidernas__figure img {
    width: 100%;
    max-width: 400px;
    height: auto;
    border-radius: 0.5rem;
    /* box-shadow: 0 2px 16px rgba(0, 0, 0, 0.1); */ /* Removed box shadow */
    display: block;
    margin: 0 auto;
    /* filter: drop-shadow(0 18px 34px rgba(0, 0, 0, 0.45)); */ /* Removed drop shadow */
}

.design-guidernas__figure figcaption {
    margin-top: 0.75rem;
    font-family: 'Nixie One', serif; /* Changed from cursive to serif */
    font-size: 0.95rem;
    letter-spacing: 0.08em;
    text-transform: lowercase;
    color: rgba(230, 231, 242, 0.65);
}

.design-guidernas__link {
    color: #d7af6b;
    text-decoration: underline;
    text-decoration-thickness: 2px;
    text-decoration-color: rgba(215, 175, 107, 0.6);
}

.design-guidernas__link:hover,
.design-guidernas__link:focus {
    color: #f4dca8;
}

.design-guidernas sup {
    font-size: 0.75em;
    vertical-align: super;
    margin-left: 0.1em;
}

.design-plasmid {
    padding-top: clamp(4rem, 9vw, 6.5rem);
    padding-bottom: clamp(1rem, 2.5vw, 1.7rem);
}

.design-plasmid__inner {
    max-width: min(1180px, 94vw);
    margin: 0 auto;
    text-align: center;
}

.design-plasmid__title {
    font-family: 'Fraunces', serif;
    font-weight: bold;
    font-size: clamp(2rem, 4vw, 3.5rem); /* Standardized to match other pages */
    color: #d7af6b;
    margin: 0.5rem 0 0.25rem 0; /* Minimal margin */
    text-align: left;
    text-shadow: 0 18px 36px rgba(0, 0, 0, 0.45);
}

.design-plasmid__lead {
    font-family: 'Nixie One', serif; /* Changed from cursive to serif */
    font-size: clamp(1.2rem, 2.4vw, 1.45rem);
    line-height: 1.85;
    color: rgba(230, 231, 242, 0.88);
    max-width: 90ch;
    margin: 0 auto clamp(3.5rem, 7vw, 4.5rem);
}

.design-plasmid__fragments {
    display: grid;
    gap: clamp(0.4rem, 1.2vw, 1rem);
}

.design-plasmid__fragment {
    text-align: left;
    display: grid;
    gap: clamp(0.05rem, 0.2vw, 0.1rem); /* Reduced gap between title and image */
}

/* Specific spacing reduction for fragment subsection titles */
.design-plasmid__fragment .subsection-title {
    margin-bottom: 0.1rem !important; /* Very small margin below fragment titles */
}

.design-plasmid__fragment-title {
    font-family: 'Fraunces', serif;
    font-weight: bold; /* Changed from 600 to bold */
    font-size: clamp(1.6rem, 4.5vw, 2.3rem);
    color: #afc1d0;
    margin: 0 0 clamp(0.2rem, 0.8vw, 0.6rem);
    text-align: left;
}

.design-plasmid__figure {
    margin: 0.25rem 0; /* Minimal positive margins instead of negative */
    text-align: center;
}

.design-plasmid__figure img {
    width: min(100%, 1100px);
    height: auto;
    display: block;
    margin: 0 auto;
    filter: drop-shadow(0 18px 34px rgba(0, 0, 0, 0.45));
}

.design-fragments {
    padding-top: clamp(0.9rem, 2.2vw, 1.4rem);
    padding-bottom: clamp(3.5rem, 8vw, 5.5rem);
}

.design-fragments__inner {
    max-width: min(1220px, 95vw);
    margin: 0 auto;
    text-align: center;
}

.design-fragments__title {
    font-family: 'Fraunces', serif;
    font-weight: bold;
    font-size: clamp(1.6rem, 4.2vw, 2.6rem);
    color: #afc1d0;
    margin: 0 0 clamp(2rem, 5vw, 3rem);
    text-shadow: 0 18px 36px rgba(0, 0, 0, 0.45);
}

.design-fragments__list {
    display: flex;
    justify-content: center;
    gap: 0;
    position: relative;
}

.design-fragments__item {
    position: relative;
    flex: 1 1 0;
    padding: 0 clamp(1rem, 2vw, 1.75rem);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    min-height: clamp(11rem, 24vw, 14rem);
    border-right: 2px solid rgba(215, 175, 107, 0.85);
}

.design-fragments__item:last-child {
    border-right: none;
}

.design-fragments__text {
    font-family: 'Nixie One', serif;
    font-size: clamp(1.15rem, 1.45vw, 1.45rem); /* Match paragraph size */
    line-height: 1.6; /* Match paragraph line height */
    color: #ffffff; /* Match paragraph color */
    margin: 0.75rem 0; /* Match paragraph margins */
    text-align: left; /* Left align like other paragraphs */
}

@media (max-width: 1024px) {
    .design-fragments__list {
        flex-direction: column;
        gap: clamp(1.75rem, 3.5vw, 2.5rem);
    }

    .design-fragments__item {
        padding: 0;
        border-right: none;
        border-bottom: 2px solid rgba(215, 175, 107, 0.65);

    .design-hairpin-sequences__figures {
        gap: clamp(0.05rem, 0.1vw, 0.1rem);
    }

    .design-hairpin-sequences__image {
        width: 100%;
    }

    .design-hairpin-sequences {
        margin-top: -3.75rem;
        margin-bottom: -2.75rem;
    }

    .design-hairpin-sequences__image + .design-hairpin-sequences__image {
        margin-top: clamp(-13rem, -32vw, -8rem);
    }
    }

    .design-fragments__item:last-child {
        border-bottom: none;
    }

    .design-hairpin__content {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: clamp(0.1rem, 0.2vw, 0.15rem);
    }

    .design-hairpin__copy {
        text-align: center;
    }

    .design-hairpin__list {
        padding-left: 0;
        list-style-position: inside;
        justify-items: center;
    }

    .design-hairpin__figure {
        grid-template-columns: 1fr;
        gap: clamp(0.05rem, 0.1vw, 0.1rem);
    }

    .design-hairpin__label {
        text-align: center;
    }
}

.design-transformation {
    padding-top: clamp(3.5rem, 8vw, 5.75rem);
    padding-bottom: clamp(3.5rem, 8vw, 5.75rem);
}

.design-transformation__inner {
    max-width: min(1260px, 94vw);
    margin: 0 auto;
    text-align: center;
}

.design-transformation__title {
    font-family: 'Fraunces', serif;
    font-weight: bold;
    font-size: clamp(2rem, 4vw, 3.5rem); /* Standardized to match other pages */
    color: #d7af6b;
    margin: 0.5rem 0 0.25rem 0; /* Minimal margin */
    text-shadow: 0 18px 36px rgba(0, 0, 0, 0.45);
}

.design-transformation__body {
    font-family: 'Nixie One', serif;
    font-size: clamp(1.15rem, 1.45vw, 1.45rem);
    line-height: 1.6;
    color: #ffffff;
    margin: 1.5rem 0;
    text-align: left;
}

.design-protein {
    padding-top: clamp(3.5rem, 8vw, 5.5rem);
    padding-bottom: clamp(3.5rem, 8vw, 5.5rem);
}

.design-protein__inner {
    max-width: min(1260px, 94vw);
    margin: 0 auto;
    text-align: center;
}

.design-protein__title {
    font-family: 'Fraunces', serif;
    font-weight: bold;
    font-size: clamp(2rem, 4vw, 3.5rem); /* Standardized to match other pages */
    color: #d7af6b;
    margin: 0.5rem 0 0.25rem 0; /* Minimal margin */
    text-shadow: 0 18px 36px rgba(0, 0, 0, 0.45);
}

.design-protein__body {
    font-family: 'Nixie One', serif;
    font-size: clamp(1.15rem, 1.45vw, 1.45rem);
    line-height: 1.6;
    color: #ffffff;
    margin: 1.5rem 0;
    text-align: left;
}

.design-purification {
    padding-top: clamp(3.5rem, 8vw, 5.5rem);
    padding-bottom: clamp(3.5rem, 8vw, 5.5rem);
}

.design-purification__inner {
    max-width: min(1260px, 94vw);
    margin: 0 auto;
    text-align: center;
}

.design-purification__title {
    font-family: 'Fraunces', serif;
    font-weight: bold;
    font-size: clamp(2rem, 4vw, 3.5rem); /* Standardized to match other pages */
    color: #d7af6b;
    margin: 1rem 0 0.5rem 0; /* Reduced margin to match other titles */
    text-shadow: 0 18px 36px rgba(0, 0, 0, 0.45);
}

.design-purification__body {
    font-family: 'Nixie One', serif;
    font-size: clamp(1.15rem, 1.45vw, 1.45rem);
    line-height: 1.6;
    color: #ffffff;
    margin: 1.5rem 0;
    text-align: left;
}

.design-hairpin {
    padding-top: clamp(3.5rem, 8vw, 5.75rem);
    padding-bottom: 0;
}

.design-hairpin__inner {
    max-width: min(1240px, 94vw);
    margin: 0 auto;
}

.design-hairpin__title {
    font-family: 'Fraunces', serif;
    font-weight: bold;
    font-size: clamp(1.45rem, 3.6vw, 2.35rem);
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #a3213b;
    text-align: center;
    margin: 0 0 clamp(3rem, 8vw, 5.5rem);
    text-shadow: 0 18px 36px rgba(0, 0, 0, 0.45);
}

.design-hairpin__content {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: clamp(3rem, 6vw, 5rem);
}

.design-hairpin__copy {
    flex: 1 1 52%;
    text-align: left;
    display: grid;
    gap: clamp(1.5rem, 3vw, 2.5rem);
}

.design-hairpin__subtitle {
    font-family: 'Fraunces', serif;
    font-weight: 600;
    font-size: clamp(1.5rem, 3vw, 2.5rem);
    color: #afc1d0;
    margin: 2.5rem 0 1.5rem 0;
    text-align: left;
    line-height: 1.3;
}

.design-hairpin__body {
    font-family: 'Nixie One', serif;
    font-size: clamp(1.15rem, 1.45vw, 1.45rem);
    line-height: 1.6;
    color: #ffffff;
    margin: 1.5rem 0;
    text-align: left;
}

.design-hairpin__list {
    margin: 0;
    padding-left: 1.25rem;
    display: grid;
    gap: clamp(0.9rem, 2.3vw, 1.3rem);
    font-family: 'Nixie One', serif;
    font-size: clamp(1.2rem, 2.5vw, 1.45rem);
    line-height: 1.85;
    color: rgba(230, 231, 242, 0.9);
}

.design-hairpin__item {
    margin: 0;
}


.design-hairpin__figures {
    flex: 0 0 auto;
    display: grid;
    gap: clamp(0.1rem, 0.2vw, 0.15rem);
}

.design-hairpin__figure {
    display: grid;
    grid-template-columns: auto 1fr;
    align-items: center;
    gap: clamp(0.1rem, 0.2vw, 0.15rem);
}

.design-hairpin__label {
    font-family: 'Nixie One', serif;
    font-size: clamp(1.1rem, 2.4vw, 1.4rem);
    letter-spacing: 0.08em;
    color: rgba(230, 231, 242, 0.85);
    text-align: right;
}

.design-hairpin__image {
    width: min(540px, 60vw);
    height: auto;
    display: block;
    filter: drop-shadow(0 18px 34px rgba(0, 0, 0, 0.45));
}



.design-hairpin-sequences {
    padding-top: clamp(0rem, 0vw, 0rem);
    padding-bottom: clamp(0.25rem, 1.4vw, 0.75rem);
    margin-top: calc(-1 * clamp(4.5rem, 11vw, 6.5rem));
    margin-bottom: clamp(-6rem, -14vw, -3.75rem);
}


.design-hairpin-sequences__inner {
    max-width: min(1340px, 96vw);
    margin: 0 auto;
}


.design-hairpin-sequences__figures {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: clamp(1rem, 3vw, 2rem);
}

.design-hairpin-sequences__image {
    width: min(1280px, 94vw);
    height: auto;
    display: block;
    max-width: 100%;
}

.design-hairpin-sequences__image + .design-hairpin-sequences__image {
    margin-top: 0;
}

/* Responsive behavior for sequence images */
@media screen and (max-width: 1024px) {
    .design-hairpin-sequences__figures {
        gap: clamp(1.5rem, 4vw, 2.5rem);
    }
    
    .design-hairpin-sequences__image {
        width: min(90vw, 800px);
    }
}

@media screen and (max-width: 768px) {
    .design-hairpin-sequences__figures {
        gap: 2rem;
    }
    
    .design-hairpin-sequences__image {
        width: min(95vw, 600px);
    }
}


.design-hairpin-init {
    padding-top: 0 !important;
    padding-bottom: clamp(1.05rem, 3.2vw, 2.2rem);
}

.design-hairpin-init__inner {
    max-width: min(1200px, 94vw);
    margin: 0 auto;
    display: grid;
    gap: 0 !important;
}

.design-hairpin-init__copy {
    display: grid;
    gap: clamp(0.1rem, 0.2vw, 0.2rem);
    text-align: left;
    margin: 0.75rem 0; /* Fixed margin to match paragraphs */
    font-family: 'Nixie One', serif;
    font-size: clamp(1.15rem, 1.45vw, 1.45rem);
    line-height: 1.6;
    color: #ffffff;
}

.design-hairpin-init__copy ol {
    margin: 0 auto;
    padding-left: 0;
    text-align: center;
    list-style: none;
    display: grid;
    gap: clamp(0.6rem, 1.4vw, 0.9rem);
}

.design-hairpin-init__copy li {
    font-family: 'Nixie One', serif;
    font-size: clamp(1.25rem, 2.6vw, 1.55rem);
    line-height: 1.8;
    color: rgba(230, 231, 242, 0.9);
}

.design-hairpin-init__figures {
    display: grid;
    justify-items: center;
    gap: 0 !important;
    margin: -50px 0 -80px 0 !important;
    padding: 0 !important;
    row-gap: 0 !important;
    grid-row-gap: 0 !important;
    overflow: hidden !important;
}

.design-hairpin-init__image {
    width: min(980px, 92vw);
    height: auto;
    display: block;
    margin: 0 !important;
    padding: 0 !important;
    line-height: 0 !important;
    object-fit: cover !important;
    object-position: center !important;
    clip-path: inset(40% 10% 25% 10%) !important;
}

.design-hairpin-init__image + .design-hairpin-init__image {
    margin-top: -15% !important;
    transform: translateY(-15%) !important;
}

.design-hairpin-h2 {
    max-width: min(1100px, 92vw);
    margin: clamp(1.5rem, 3.6vw, 2.25rem) auto 0;
    padding: 0 clamp(0.75rem, 3vw, 1.25rem);
    display: grid;
    gap: clamp(1.35rem, 3vw, 2rem);
    text-align: left;
}

.design-hairpin-h2__title,
.design-hairpin-h2__subtitle {
    font-family: 'Fraunces', serif;
    font-weight: bold;
    letter-spacing: 0.02em;
    color: #afc1d0;
    margin: 0;
}

.design-hairpin-h2__title {
    font-size: clamp(2.4rem, 6.4vw, 3.6rem);
}

.design-hairpin-h2__subtitle {
    font-size: clamp(1.9rem, 5vw, 2.8rem);
    margin-top: clamp(1.75rem, 4.5vw, 2.8rem);
}

.design-hairpin-h2__copy {
    font-family: 'Nixie One', serif;
    font-size: clamp(1.2rem, 2.5vw, 1.55rem);
    line-height: 1.85;
    color: rgba(216, 223, 236, 0.92);
    margin: 0;
    max-width: 78ch;
}

.design-hairpin-comparison {
    max-width: min(1200px, 94vw);
    margin: clamp(2.5rem, 5.5vw, 3.6rem) auto 0;
    display: grid;
    gap: clamp(2rem, 4.5vw, 3rem);
    justify-items: center;
}

.design-hairpin-comparison__panel {
    position: relative;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    column-gap: clamp(1.5rem, 4vw, 2.75rem);
    padding: clamp(2rem, 5vw, 3.5rem) clamp(1.25rem, 4vw, 2.5rem);
}

/* Narrow laptop screens - reduce gap but keep side by side */
@media screen and (max-width: 1024px) and (min-width: 769px) {
    .design-hairpin-comparison__panel {
        column-gap: clamp(0.5rem, 2vw, 1.5rem);
        padding: clamp(1.5rem, 4vw, 2.5rem) clamp(0.5rem, 2vw, 1.5rem);
    }
    
    .design-hairpin-comparison__column {
        max-width: 45%;
        min-width: 300px;
    }
}

/* Mobile and small tablets - stack vertically */
@media screen and (max-width: 768px) {
    .design-hairpin-comparison__panel {
        column-gap: 0;
        flex-direction: column;
        row-gap: 2rem;
        align-items: center;
    }
    
    .design-hairpin-comparison__panel::after {
        display: none;
    }
    
    .design-hairpin-comparison__column {
        max-width: 100%;
        text-align: center;
        align-items: center;
    }
    
    .design-hairpin-comparison__column:first-child .paragraph,
    .design-hairpin-comparison__column:first-child .design-hairpin-comparison__title {
        text-align: center !important;
    }
}

.design-hairpin-comparison__panel::after {
    content: "";
    position: absolute;
    top: clamp(0.5rem, 1.2vw, 1rem);
    bottom: clamp(0.5rem, 1.2vw, 1rem);
    left: 50%;
    width: 3px;
    background: rgba(215, 175, 107, 0.88);
    transform: translateX(-50%);
}

.design-hairpin-comparison__column {
    display: flex;
    flex-direction: column;
    gap: clamp(0.9rem, 2.2vw, 1.4rem);
    max-width: min(36ch, 100%);
}

.design-hairpin-comparison__column:first-child {
    text-align: right;
    align-items: flex-end;
}

.design-hairpin-comparison__column:first-child .paragraph {
    text-align: right;
}

.design-hairpin-comparison__column:last-child {
    text-align: left;
    align-items: flex-start;
}

.design-hairpin-comparison__title {
    font-family: 'Fraunces', serif;
    font-weight: bold;
    font-size: clamp(2rem, 5.5vw, 2.7rem);
    color: #d7af6b;
    margin: 0 0 clamp(1.45rem, 3.5vw, 2.1rem);
}

.design-hairpin-comparison__details {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: clamp(0.9rem, 2.2vw, 1.4rem);
    font-family: 'Nixie One', serif;
    font-size: clamp(1.15rem, 2.4vw, 1.5rem);
    line-height: 1.85;
    color: rgba(230, 231, 242, 0.92);
}

.design-hairpin-comparison__note {
    font-family: 'Nixie One', serif;
    font-size: clamp(1.1rem, 2.3vw, 1.45rem);
    line-height: 1.8;
    color: rgba(230, 231, 242, 0.88);
    margin: 0 0 clamp(2.2rem, 5vw, 3.2rem);
    text-align: center;
}

.design-hairpin-comparison__link {
    color: #d7af6b;
    text-decoration: underline;
    text-decoration-thickness: 2px;
    text-underline-offset: 0.25em;
}

.design-hairpin-comparison__link:hover,
.design-hairpin-comparison__link:focus {
    color: #f4dca8;
}

.design-hairpin-reaction {
    max-width: min(1200px, 94vw);
    margin: clamp(3rem, 6vw, 4.5rem) auto 0;
    width: 100%;
    display: grid;
    gap: clamp(1.5rem, 4vw, 2.5rem);
    text-align: left;
    padding: 0 clamp(0.75rem, 3vw, 1.25rem);
}

.design-hairpin-reaction__title {
    font-family: 'Fraunces', serif;
    font-weight: bold;
    font-size: clamp(3rem, 8vw, 4.2rem);
    line-height: 1.1;
    color: #d7af6b;
    margin: 0;
}

.design-hairpin-reaction__copy {
    font-family: 'Nixie One', serif;
    font-size: clamp(1.25rem, 2.6vw, 1.6rem);
    line-height: 1.9;
    color: rgba(230, 231, 242, 0.92);
    margin: 0;
    max-width: 90ch;
}

.design-hairpin-page {
    max-width: min(1200px, 94vw);
    margin: clamp(3rem, 6vw, 4.5rem) auto 0;
    width: 100%;
    display: grid;
    gap: clamp(1.5rem, 4vw, 2.5rem);
    text-align: left;
    padding: 0 clamp(0.75rem, 3vw, 1.25rem);
}

.design-hairpin-page__title {
    font-family: 'Fraunces', serif;
    font-weight: bold;
    font-size: clamp(3rem, 8vw, 4.2rem);
    line-height: 1.1;
    color: #d7af6b;

    .design-hairpin-sequences__figures {
        gap: clamp(1.5rem, 6vw, 2.4rem);
        margin-bottom: clamp(1.8rem, 7vw, 2.6rem);
    }

    .design-hairpin-sequences__image + .design-hairpin-sequences__image {
        margin-top: 0;
    }
    margin: 0;
}

.design-hairpin-page__copy {
    font-family: 'Nixie One', serif;
    font-size: clamp(1.25rem, 2.6vw, 1.6rem);
    line-height: 1.9;
    color: rgba(230, 231, 242, 0.92);
    margin: 0;
    max-width: 90ch;
}

.design-hairpin-band {
    max-width: min(1200px, 94vw);
    margin: clamp(3rem, 6vw, 4.5rem) auto 0;
    width: 100%;
    display: grid;
    gap: clamp(1.5rem, 4vw, 2.5rem);
    text-align: left;
    padding: 0 clamp(0.75rem, 3vw, 1.25rem);
}

.design-hairpin-band__title {
    font-family: 'Fraunces', serif;
    font-weight: bold;
    font-size: clamp(3rem, 8vw, 4.2rem);
    line-height: 1.1;
    color: #d7af6b;
    margin: 0;
}

.design-hairpin-band__copy {
    font-family: 'Nixie One', serif;
    font-size: clamp(1.25rem, 2.6vw, 1.6rem);
    line-height: 1.9;
    color: rgba(230, 231, 242, 0.92);
    margin: 0;
    max-width: 90ch;
}

.design-references__inner {
    max-width: min(1100px, 92vw);
    margin: clamp(2.5rem, 5.5vw, 3.6rem) auto 0;
    display: grid;
    gap: clamp(1.5rem, 4vw, 2.4rem);
    text-align: left;
    padding: 0 clamp(0.75rem, 3vw, 1.25rem);
}

.design-references__title {
    font-family: 'Fraunces', serif;
    font-weight: bold;
    font-size: clamp(3rem, 8vw, 4.2rem);
    line-height: 1.1;
    color: "#d7af6b";
    margin: 0;
}

.design-references__list {
    font-family: 'Nixie One', serif !important;
    font-size: clamp(1.15rem, 1.45vw, 1.45rem) !important;
    color: white !important;
    line-height: 1.8 !important;
    margin: 2rem 0;
    padding-left: 2rem;
}

.design-references__list li {
    margin: 0;
}

.design-references__list p {
    margin: 0;
}

.design-references__list p + p {
    margin-top: clamp(0.4rem, 1.2vw, 0.8rem);
}

.design-references__doi {
    color: rgba(215, 175, 107, 0.92);
}
@media (max-width: 768px) {
    .design-section {
        padding: clamp(2rem, 9vw, 3rem) 1.25rem;
    }

    .design-plasmid__fragments {
        gap: clamp(2.25rem, 7vw, 3.4rem);
    }

    .design-plasmid__fragment {
        gap: clamp(0.6rem, 2.4vw, 1.1rem);
    }

    .design-plasmid__figure {
        margin: 0.1rem 0 !important; /* Minimal margins */
    }


    .design-hairpin-sequences {
        margin-top: clamp(1rem, 4vw, 2rem);
        margin-bottom: clamp(5rem, 20vw, 8.5rem);
    }

    .design-hairpin-sequences__image + .design-hairpin-sequences__image {
        margin-top: clamp(1rem, 4vw, 2rem);
    }

    .design-hairpin-init__image + .design-hairpin-init__image {
        margin-top: clamp(2rem, 12vw, 3.5rem) !important;
    }

    .design-hairpin-init__figures {
        margin: clamp(3rem, 14vw, 5.5rem) 0 clamp(2rem, 9vw, 3.5rem) 0 !important;
        padding: 0 !important;
        gap: clamp(1rem, 6vw, 2rem) !important;
    }

    .design-hairpin-init__copy {
        margin: clamp(4.5rem, 20vw, 8rem) 0 0 0 !important;
        gap: clamp(1rem, 5vw, 1.8rem);
    }

    .design-hairpin-h2 {
        margin-top: clamp(6rem, 20vw, 9rem);
        padding: 0 clamp(0.5rem, 7vw, 1.1rem);
        gap: clamp(1rem, 5vw, 1.6rem);
    }



    .design-hairpin-comparison__details {
        gap: clamp(0.75rem, 4vw, 1.25rem);
    }

    .design-hairpin-reaction {
        text-align: center;
        gap: clamp(1.25rem, 6vw, 2rem);
    }

    .design-hairpin-reaction__title {
        font-size: clamp(2.4rem, 9vw, 3.5rem);
    }

    .design-hairpin-reaction__copy {
        margin: 0 auto;
    }

    .design-hairpin-reaction,
    .design-hairpin-page,
    .design-hairpin-band {
        padding: 0 clamp(0.5rem, 7vw, 1.1rem);
    }

    .design-hairpin-page {
        text-align: center;
        gap: clamp(1.25rem, 6vw, 2rem);
    }

    .design-hairpin-page__title {
        font-size: clamp(2.4rem, 9vw, 3.5rem);
    }

    .design-hairpin-page__copy {
        margin: 0 auto;
    }

    .design-hairpin-band {
        text-align: center;
        gap: clamp(1.25rem, 6vw, 2rem);
    }

    .design-hairpin-band__title {
        font-size: clamp(2.4rem, 9vw, 3.5rem);
    }

    .design-hairpin-band__copy {
        margin: 0 auto;
    }

    .design-references__inner {
        gap: clamp(1.25rem, 6vw, 2rem);
        text-align: center;
        padding: 0 clamp(0.5rem, 7vw, 1.1rem);
    }

    .design-references__title {
        font-size: clamp(2.4rem, 9vw, 3.5rem);
    }

    .design-references__list {
        padding-left: clamp(1.5rem, 7vw, 2.25rem);
        text-align: left;
    }

}

@media (max-width: 900px) {
    .design-hero {
        padding-top: calc(90px + clamp(5rem, 18vw, 8rem)); /* Account for navbar on mobile */
        min-height: 70vh;
    }

    .design-hero__ring {
        width: clamp(280px, 48vw, 420px);
        opacity: 0.75;
    }

    .design-hero__ring--left {
        top: 38%;
        left: -17vw;
    }

    .design-hero__ring--right {
        top: 20%;
        right: -17vw;
    }

    .design-guidernas__figures {
        gap: clamp(2rem, 8vw, 3rem);
    }

}

@media (max-width: 600px) {
    .design-hero__ring {
        width: clamp(240px, 62vw, 340px);
        opacity: 0.6;
    }

    .design-hero__ring--left,
    .design-hero__ring--right {
        position: absolute;
        top: auto;
        bottom: auto;
    }

    .design-hero__ring--left {
        top: 38%;
        left: -30vw;
    }

    .design-hero__ring--right {
        top: 22%;
        right: -30vw;
    }

    .design-guidernas__figures {
        flex-direction: column;
        align-items: center;
    }

    .design-hairpin-init__image {
        width: 100%;
    }

    .design-hairpin-init__image + .design-hairpin-init__image {
        margin-top: -5px !important;
    }

    .design-hairpin-init__figures {
        margin: 0 !important;
        padding: 0 !important;
        gap: 0 !important;
    }
}

/* Under development container */
.under-development {
    background-color: #0b1320;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100vw;
    margin-left: calc(-50vw + 50%);
    padding: 2rem 0;
    margin-top: -80px; /* Move content up */
}

/* Content wrapper */
.content-wrapper {
    text-align: center;
    z-index: 2;
    transform: translateY(-50px); /* Move content further up */
}

/* Development image */
.dev-image {
    width: 400px; /* Increased from 200px */
    height: auto;
    opacity: 0.8;
    animation: float 4s ease-in-out infinite;
    margin-bottom: 1.5rem; /* Reduced margin to bring text closer */
}

/* Floating animation */
@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-15px);
    }
}

/* Development message */
.dev-message {
    font-family: 'Fraunces', serif;
    font-weight: bold;
    font-size: clamp(1.6rem, 4.5vw, 2.4rem);
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #d7af6b;
    margin: 0;
}

/* Responsive design */
@media (max-width: 768px) {
    .dev-image {
        width: 220px; /* Increased from 150px */
    }
    
    .dev-message {
        font-size: 1.5rem;
        letter-spacing: 1px;
    }
    
    .under-development {
        margin-top: -60px; /* Less adjustment on tablets */
    }
    
    .content-wrapper {
        transform: translateY(-30px); /* Less movement on tablets */
    }
}

@media (max-width: 480px) {
    .dev-image {
        width: 180px; /* Increased from 120px */
    }
    
    .dev-message {
        font-size: 1.2rem;
        letter-spacing: 0.5px;
    }
    
    .under-development {
        margin-top: -40px; /* Even less on mobile */
    }
    
    .content-wrapper {
        transform: translateY(-20px); /* Minimal movement on mobile */
    }
}

/* READ MORE link styling - matches model page */
.read-more-link {
    color: white;
    text-decoration: underline;
    font-weight: normal;
}

.read-more-link:hover {
    color: #d7af6b;
    text-decoration: underline;
}

/* Reference link styling - matches model page */
.reference-link {
    color: white;
    text-decoration: underline;
    font-weight: normal;
}

.reference-link:hover {
    color: #d7af6b;
    text-decoration: underline;
}

/* Custom bullet list styling - matches model page */
.mylist {
    font-family: 'Nixie One', serif;
    font-size: clamp(1.15rem, 1.45vw, 1.45rem);
    color: white;
    margin: 1.5rem 0;
    text-align: left;
    line-height: 1.6;
    list-style: none;
    padding-left: 0;
}

.mylist li {
    margin: 0.8rem 0;
    padding-left: 6rem;
    position: relative;
}

.mylist li::before {
    content: '';
    position: absolute;
    left: 0;
    top: -1.5rem;
    width: 5rem;
    height: 5rem;
    background-image: url('https://static.igem.wiki/teams/5836/model/special/bullet.svg');
    background-size: contain;
    background-repeat: no-repeat;
}

/* No-wrap modifier for specific lists */
.mylist--nowrap li {
    white-space: nowrap;
}

/* Mobile responsive mylist styling */
@media (max-width: 768px) {
    .mylist li {
        padding-left: 4rem;
    }
    
    .mylist li::before {
        width: 3rem;
        height: 3rem;
        top: -0.5rem;
    }
    
    .mylist--nowrap li {
        white-space: nowrap;
    }
}

/* Supersection title styling - same as section but with different color */
.supersection-title {
    font-family: 'Fraunces', serif;
    font-weight: bold;
    font-size: clamp(2rem, 4vw, 3.5rem);
    color: #6e0d25; /* Special color for supersections */
    margin: 0.5rem 0 0.25rem 0; /* Further reduced margins */
    text-align: left;
    line-height: 1.2;
}

/* Hairpin details styling to match paragraphs */
.hairpin-details {
    margin: 0.5rem 0;
}

.hairpin-details .paragraph {
    margin: 0.25rem 0; /* Tighter spacing within details */
    font-size: clamp(1.05rem, 1.35vw, 1.35rem); /* Slightly smaller for details */
}

/* Ensure H1 hairpin probe content is right-aligned with higher specificity */
.design-hairpin-comparison__column:first-child .hairpin-details .paragraph {
    text-align: right !important;
}

.design-hairpin-comparison__column:first-child .design-hairpin-comparison__title {
    text-align: right !important;
}

/* Cropping for specific fragment images - 25% from top and bottom */
.design-plasmid__figure img[src*="4.webp"],
.design-plasmid__figure img[src*="5.webp"] {
    object-fit: cover;
    object-position: center;
    height: 429px; /* 10% bigger than 390px (390 * 1.1 = 429px) */
    width: 100%;
    max-width: 858px; /* 10% bigger than 780px (780 * 1.1 = 858px) */
    clip-path: inset(25% 0 25% 0); /* Crop 25% from top and bottom */
}

/* Mobile responsive fragment images */
@media (max-width: 768px) {
    .design-plasmid__figure img[src*="4.webp"],
    .design-plasmid__figure img[src*="5.webp"] {
        height: auto !important; /* Auto height to prevent truncation */
        max-width: 90% !important; /* Smaller width to fit mobile screens */
        width: 90% !important; /* Ensure proper sizing */
        clip-path: none !important; /* Remove cropping on mobile to prevent truncation */
        object-fit: contain !important; /* Show full image without cropping */
    }
    
    /* Remove all margins on mobile for fragment figures */
    .design-plasmid__figure {
        margin: 0.1rem 0 !important;
    }
}

/* General image centering and overlap prevention */
.design-section img {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 0 auto;
}

/* Minimal spacing around all figures */
.design-section figure {
    margin: 0.25rem 0; /* Very minimal margins */
}

/* Mobile spacing reduction for all figures */
@media (max-width: 768px) {
    .design-section figure {
        margin: 0.1rem 0; /* Almost no margins on mobile */
    }
    
    .design-workflow__figure {
        margin: 0.1rem 0; /* Almost no margins on mobile */
    }
    
    /* Specific mobile spacing reduction for final1.webp, final2.webp images */
    .design-guidernas__figures {
        margin: 0.2rem auto !important; /* Minimal margin instead of 1rem */
        gap: 0.5rem !important; /* Reduced gap between images */
    }
    
    .design-guidernas__figure {
        margin: 0 !important; /* Remove all margins */
    }
    
    /* Specific mobile spacing reduction for 10.webp, 11.webp images */
    .design-hairpin-sequences__figures {
        margin: 1rem 0 !important; /* Proper spacing */
        display: flex;
        flex-direction: column;
        gap: 1rem;
        align-items: center;
    }
    
    .design-hairpin-sequences__image {
        width: min(100%, 90vw);
        max-width: 500px;
        height: auto;
    }
    
    .design-hairpin-sequences__image + .design-hairpin-sequences__image {
        margin-top: 0 !important; /* Remove negative margin completely */
    }
    
    .design-hairpin-init__figures {
        margin: 0.1rem 0 !important; /* Minimal margins instead of -50px 0 -80px 0 */
    }
    
    .design-hairpin-init__image {
        clip-path: inset(30% 5% 15% 5%) !important; /* Less aggressive cropping on mobile */
    }
    
    .design-hairpin-init__image + .design-hairpin-init__image {
        margin-top: -5% !important; /* Reduced negative margin */
        transform: translateY(-5%) !important; /* Reduced transform */
    }
    
    /* Reduce spacing under image 7 (hairpin H2 probe) */
    .design-hairpin__figures {
        margin-bottom: 0.2rem !important; /* Minimal bottom margin */
        gap: 0.1rem !important; /* Reduced gap */
    }
    
    .design-hairpin__figure {
        margin-bottom: 0.1rem !important; /* Minimal bottom margin */
    }
    
    /* Additional spacing reduction for sections after image 11 */
    .design-hairpin-init__copy {
        margin-top: 0.2rem !important; /* Reduced top margin after image 11 */
        padding-top: 0.1rem !important;
    }
    
    /* Reduce spacing in hairpin-init section */
    .design-hairpin-init {
        padding-bottom: 0.5rem !important; /* Reduced bottom padding */
    }
}

.design-section figure {
    text-align: center;
    margin: 1.5rem 0;
}

/* Ensure all content stays within bounds and doesn't overlap navigation */
.design-section {
    position: relative;
    overflow-x: hidden;
}

/* Global left alignment for all titles and paragraphs */
.design-section h1,
.design-section h2,
.design-section h3,
.design-section h4,
.design-section h5,
.design-section h6,
.design-section p {
    text-align: left !important;
}