@import url('https://fonts.googleapis.com/css2?family=Onest:wght@100..900&display=swap');

:root {
    --premium-bg: #f6f7f8;
    --premium-surface: #ffffff;
    --premium-surface-soft: #f3f5f7;
    --premium-text: #27292d;
    --premium-muted: #6f7680;
    --premium-line: #e6e9ed;
    --premium-blue: #3b82f6;
    --premium-shadow: 0 12px 34px rgba(31, 41, 55, 0.08);
}

* {
    box-sizing: border-box;
    font-family: 'Onest', Arial, sans-serif;
    caret-color: transparent;
}

html,
body {
    margin: 0;
    min-height: 100%;
}

body {
    background: var(--premium-bg);
    color: var(--premium-text);
    overflow-x: hidden;
}

.premium-container {
    width: 100%;
    min-height: 100svh;
    padding: clamp(4.55rem, 8vh, 5.5rem) clamp(1.2rem, 3vw, 2rem) clamp(1rem, 2.4vh, 1.6rem);
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--premium-bg);
}

.premium-shell {
    width: min(100%, 73rem);
    height: min(43.5rem, calc(100svh - 7.2rem));
    min-height: 37rem;
    display: grid;
    grid-template-columns: minmax(0, 1.23fr) minmax(19rem, 0.77fr);
    gap: 1.2rem;
}

.premium-offer,
.premium-feature {
    border: 1px solid var(--premium-line);
    background: var(--premium-surface);
    box-shadow: var(--premium-shadow);
}

.premium-offer {
    grid-column: 2;
    grid-row: 1;
    min-width: 0;
    padding: 1.35rem clamp(1.65rem, 3.2vh, 2.35rem);
    border-radius: 1.55rem;
    display: flex;
    flex-direction: column;
}

.premium-eyebrow {
    display: inline-flex;
    align-items: center;
    align-self: flex-start;
    gap: .5rem;

    padding: 0;
    margin: 0;
    min-height: 0;

    background: transparent;
    color: #8a929d;

    font-size: .72rem;
    font-weight: 700;
    line-height: 1;
    letter-spacing: .055em;
    text-transform: uppercase;
}

.premium-eyebrow img {
    width: 1.14rem;
    height: 1.14rem;
    object-fit: contain;
}

.premium-copy {
    margin-top: .5rem;
}

.premium-copy h1 {
    margin: 0;
    max-width: 25rem;
    color: var(--premium-text);
    font-size: clamp(2.15rem, 3.5vw, 3.35rem);
    font-weight: 650;
    line-height: 1.02;
    letter-spacing: -.045em;
}

.premium-benefits {
    margin: 1.05rem 0 0;
    padding: 0;
    display: grid;
    gap: .5rem;
    list-style: none;
}

.premium-benefits li {
    position: relative;
    min-width: 0;
    padding-left: 1.45rem;
    color: var(--premium-muted);
    font-size: clamp(.9rem, 1.05vw, 1rem);
    font-weight: 470;
    line-height: 1.46;
}

.premium-benefits li::before {
    content: "✓";
    position: absolute;
    left: 0;
    top: .02em;
    color: var(--premium-blue);
    font-size: .96em;
    font-weight: 760;
    line-height: 1.46;
}

.premium-price-card {
    margin-top: auto;
    padding-top: 1.08rem;
    border-top: 1px solid #e8ebef;
}

.premium-plan-grid {
    margin-top: 0;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .55rem;
}

.premium-plan-option {
    position: relative;
    min-width: 0;
    cursor: pointer;
}

.premium-plan-option input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.premium-plan-card {
    min-height: 7.15rem;
    padding: .82rem .86rem .78rem;
    display: flex;
    flex-direction: column;
    border: 1px solid #e1e5e9;
    border-radius: .92rem;
    background: #ffffff;
    transition: border-color .18s ease, background-color .18s ease, box-shadow .18s ease, transform .18s ease;
}

.premium-plan-option:hover .premium-plan-card {
    border-color: #cfd5dc;
    transform: translateY(-1px);
}

.premium-plan-option input:checked + .premium-plan-card {
    border-color: #3b82f6;
    box-shadow: 0 0 0 1px #3b82f6, 0 8px 22px rgba(31, 41, 55, .07);
}

.premium-plan-option input:focus-visible + .premium-plan-card {
    outline: 2px solid rgba(59, 130, 246, .38);
    outline-offset: 2px;
}

.premium-plan-option--best .premium-plan-card {
    background: #ffffff;
    border-color: #e1e5e9;
}

.premium-plan-card-head {
    min-height: 1.45rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .42rem;
}

.premium-plan-card-head b {
    color: #555c65;
    font-size: .79rem;
    font-weight: 650;
    line-height: 1.15;
}

.premium-plan-card-head em {
    padding: .22rem .4rem;
    border-radius: 999px;
    background: #e8f2ff;
    color: #3975b8;
    font-size: .6rem;
    font-style: normal;
    font-weight: 720;
    line-height: 1;
    white-space: nowrap;
    transform: translateY(-1px);
}

.premium-plan-price {
    margin-top: .62rem;
    color: #202327;
    font-size: clamp(1.55rem, 2.65vw, 2rem);
    font-weight: 720;
    line-height: 1;
    letter-spacing: -.04em;
}

.premium-plan-detail {
    margin-top: auto;
    padding-top: .55rem;
    color: #8a919a;
    font-size: .7rem;
    line-height: 1.25;
}

.premium-buy-button {
    width: 100%;
    min-height: 2.75rem;
    margin-top: .82rem;
    padding: .7rem 1rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: .82rem;
    background: #3b82f6;
    color: #ffffff !important;
    text-decoration: none;
    font-family: inherit;
    font-size: .9rem;
    font-weight: 650;
    cursor: pointer;
    transition: transform .18s ease, background-color .18s ease;
}

.premium-buy-button:hover {
    transform: translateY(-1px);
    background: #2563eb;
}

.premium-gift-note {
    margin: .72rem 0 0;
    color: #7f8790;
    font-size: .75rem;
    line-height: 1.35;
}

.premium-gift-note a {
    color: #3b82f6;
    font-weight: 600;
    text-decoration: none;
}

.premium-gift-note a:hover {
    text-decoration: underline;
    text-underline-offset: .16em;
}

.premium-showcase {
    grid-column: 1;
    grid-row: 1;
    min-width: 0;
    min-height: 0;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: minmax(0, .92fr) minmax(0, 1.08fr);
    gap: 1.2rem;
}

.premium-feature {
    position: relative;
    min-width: 0;
    min-height: 0;
    padding: 1.35rem;
    border-radius: 1.45rem;
    overflow: hidden;
}

.premium-feature--advanced,
.premium-feature--solutions {
    display: flex;
    flex-direction: column;
}

.premium-bottom-stack {
    grid-column: 1 / -1;
    min-width: 0;
    min-height: 0;
    display: grid;
    grid-template-rows: minmax(0, 1fr) 7.1rem;
    gap: 1.2rem;
}

.premium-feature--certificates {
    display: grid;
    grid-template-columns: minmax(13.5rem, .78fr) minmax(20rem, 1.22fr);
    align-items: center;
    gap: 1rem;
}

.premium-feature--support {
    padding: 1.35rem;
    display: flex;
    align-items: flex-start;
    gap: .9rem;
}

.premium-support-icon {
    position: absolute;
    right: 1.8rem;
    top: 50%;
    transform: translateY(-50%);
    width: 2.75rem;
    height: 2.75rem;
    font-size: 0;
    line-height: 0;
    background: #ffc0a6;
    -webkit-mask: url("/images/icons/mentor-robot.svg") center / contain no-repeat;
    mask: url("/images/icons/mentor-robot.svg") center / contain no-repeat;
    opacity: .78;
    pointer-events: none;
    user-select: none;
}

.premium-support-copy {
    position: relative;
    z-index: 1;
    flex: 1 1 auto;
    width: 100%;
    min-width: 0;
    padding-right: 4.8rem;
}

.premium-feature--support .premium-feature-kicker {
    margin-bottom: .5rem;
}

.premium-feature--support h2 {
    font-size: 1.08rem;
}

.premium-feature--support p {
    margin-top: .3rem;
    font-size: .78rem;
    line-height: 1.4;
}

.premium-feature-copy {
    position: relative;
    z-index: 2;
}

.premium-feature-kicker {
    display: block;
    margin-bottom: .5rem;
    color: #8a929d;
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .055em;
    text-transform: uppercase;
}

.premium-feature h2 {
    margin: 0;
    color: #2d3035;
    font-size: clamp(1.12rem, 1.7vw, 1.38rem);
    font-weight: 650;
    line-height: 1.15;
    letter-spacing: -.025em;
}

.premium-feature p {
    margin: .52rem 0 0;
    color: #747b84;
    font-size: .84rem;
    line-height: 1.5;
}

.premium-roadmap-preview {
    margin-top: auto;
    padding-top: .8rem;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: .38rem;
}

.premium-track {
    min-width: 0;
    height: 4.65rem;
    padding: .5rem .42rem;
    border-radius: .72rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-shadow: inset 0 0 0 1px rgba(31,41,55,.035);
}

.premium-track b {
    overflow: hidden;
    color: #3f454d;
    font-size: .48rem;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.premium-track i {
    width: 68%;
    height: .28rem;
    border-radius: 999px;
    background: rgba(255,255,255,.7);
    box-shadow: 0 -.7rem 0 rgba(255,255,255,.48), 0 -1.4rem 0 rgba(255,255,255,.34);
}

.premium-track--java { background: #c9e8ff; }
.premium-track--spring { background: #d1e9c6; }
.premium-track--sql { background: #fff0b8; }
.premium-track--algorithms { background: #ffcaca; }
.premium-track--system { background: #ddd8ff; }

.premium-companies-preview {
    margin-top: auto;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: .32rem;
}

.premium-companies-preview > span {
    min-width: 0;
    height: 1.7rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: .45rem;
    background: #f7f8fa;
}

.premium-companies-preview img {
    display: block;
    width: auto;
    max-width: 82%;
    max-height: .92rem;
    object-fit: contain;
    filter: grayscale(1);
    opacity: .38;
}

.premium-feature-copy--certificate {
    align-self: stretch;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.premium-certificate-tracks {
    display: block;
    margin-top: auto;
    padding-top: .75rem;
    color: #838b95;
    font-size: .68rem;
    font-weight: 550;
}

.premium-certificate-fan {
    position: relative;
    height: 100%;
    min-height: 8.4rem;
}

.premium-certificate {
    --x: 0rem;
    --r: 0deg;
    position: absolute;
    left: 50%;
    top: 50%;
    width: clamp(8.5rem, 13.8vw, 10rem);
    aspect-ratio: 1684 / 1190;
    border: 1px solid rgba(17,24,39,.055);
    border-radius: .48rem;
    background: #ffffff;
    box-shadow: 0 10px 25px rgba(31,41,55,.12);
    transform: translate(-50%, -50%) translateX(var(--x)) rotate(var(--r));
    transform-origin: center;
    overflow: hidden;
}

.premium-certificate-canvas {
    width: 100%;
    height: 100%;
    display: block;
    border-radius: inherit;
}

.premium-certificate--algorithms { --x: -6rem; --r: -7deg; z-index: 1; }
.premium-certificate--spring { --x: -3.1rem; --r: -3.5deg; z-index: 2; }
.premium-certificate--java { --x: 0rem; --r: 0deg; z-index: 5; }
.premium-certificate--sql { --x: 3.1rem; --r: 3.5deg; z-index: 3; }
.premium-certificate--system { --x: 6rem; --r: 7deg; z-index: 1; }

body.dark-theme .premium-container {
    background: #111827;
}

body.dark-theme .premium-offer,
body.dark-theme .premium-feature {
    border-color: #374151;
    background: #1f2937;
    box-shadow: 0 14px 34px rgba(0,0,0,.26);
}

body.dark-theme .premium-support-icon {
    background: #d98f73;
    opacity: .68;
}

body.dark-theme .premium-eyebrow {
    color: #9ca3af;
}

body.dark-theme .premium-price-card {
    border-top-color: #374151;
}

body.dark-theme .premium-companies-preview > span {
    background: #263241;
    border-color: #334155;
}

body.dark-theme .premium-companies-preview img {
    filter: grayscale(1) brightness(1.9);
    opacity: .42;
}

body.dark-theme .premium-eyebrow,
body.dark-theme .premium-eyebrow span {
    color: #9ca3af;
}

body.dark-theme .premium-copy h1,
body.dark-theme .premium-feature h2,
body.dark-theme .premium-plan-price {
    color: #f3f4f6;
}

body.dark-theme .premium-benefits li,
body.dark-theme .premium-feature p,
body.dark-theme .premium-certificate-tracks,
body.dark-theme .premium-plan-detail,
body.dark-theme .premium-gift-note,
body.dark-theme .premium-feature-kicker b {
    color: #9ca3af;
}

body.dark-theme .premium-gift-note a {
    color: #3b82f6 !important;
}

body.dark-theme .premium-plan-card {
    border-color: #374151;
    background: #1b2634;
}

body.dark-theme .premium-plan-option--best .premium-plan-card {
    border-color: #374151;
    background: #1b2634;
}

body.dark-theme .premium-plan-option:hover .premium-plan-card {
    border-color: #4b5563;
}

body.dark-theme .premium-plan-option input:checked + .premium-plan-card {
    border-color: #3b82f6;
    box-shadow: 0 0 0 1px #3b82f6, 0 10px 26px rgba(0, 0, 0, .22);
}

body.dark-theme .premium-plan-card-head b {
    color: #c7cdd5;
}

body.dark-theme .premium-plan-card-head em {
    background: #233c5b;
    color: #a9ccef;
}

body.dark-theme .premium-buy-button {
    background: #3b82f6;
    color: #ffffff !important;
}

body.dark-theme .premium-buy-button:hover {
    background: #2563eb;
}

body.dark-theme .premium-track {
    box-shadow: inset 0 0 0 1px rgba(255,255,255,.035);
}

body.dark-theme .premium-track--java { background: #1e3a5f; }
body.dark-theme .premium-track--spring { background: #234b35; }
body.dark-theme .premium-track--sql { background: #5a4a1f; }
body.dark-theme .premium-track--algorithms { background: #5a2a2a; }
body.dark-theme .premium-track--system { background: #312e81; }

body.dark-theme .premium-track b {
    color: #e5e7eb;
}

body.dark-theme .premium-track i {
    background: rgba(255,255,255,.18);
    box-shadow: 0 -.7rem 0 rgba(255,255,255,.12), 0 -1.4rem 0 rgba(255,255,255,.08);
}

body.dark-theme .premium-certificate {
    border-color: rgba(255,255,255,.08);
    background: #111827;
    box-shadow: 0 10px 25px rgba(0,0,0,.32);
}

@media (min-width: 981px) and (min-height: 700px) {
    .premium-feature--support p {
        white-space: nowrap;
    }
}

@media (max-width: 980px), (max-height: 699px) {
    .premium-container {
        min-height: 100svh;
        height: auto;
        align-items: flex-start;
        padding-top: 5.8rem;
        padding-bottom: 2rem;
    }

    .premium-shell {
        height: auto;
        min-height: 0;
        grid-template-columns: 1fr;
    }

    .premium-offer,
    .premium-showcase {
        grid-column: auto;
        grid-row: auto;
    }

    .premium-offer {
        min-height: 28rem;
    }

    .premium-showcase {
        grid-template-rows: auto auto;
    }

    .premium-feature--advanced,
    .premium-feature--solutions {
        min-height: 17rem;
    }

    .premium-bottom-stack {
        grid-template-rows: auto auto;
    }

    .premium-feature--certificates {
        min-height: 15.5rem;
    }

    .premium-feature--support {
        min-height: 7.1rem;
    }
}

@media (max-width: 680px) {
    .premium-container {
        padding-left: 1rem;
        padding-right: 1rem;
    }

    .premium-support-icon {
        right: 1.65rem;
        width: 2.5rem;
        height: 2.5rem;
    }

    .premium-support-copy {
        padding-right: 5.8rem;
    }

    .premium-showcase {
        grid-template-columns: 1fr;
    }

    .premium-bottom-stack {
        grid-column: auto;
    }

    .premium-feature--certificates {
        grid-template-columns: 1fr;
        min-height: 26rem;
    }

    .premium-certificate-fan {
        min-height: 12rem;
    }

    .premium-certificate {
        width: 8.4rem;
    }

    .premium-certificate--algorithms { --x: -4.8rem; }
    .premium-certificate--spring { --x: -2.4rem; }
    .premium-certificate--sql { --x: 2.4rem; }
    .premium-certificate--system { --x: 4.8rem; }
}

@media (max-width: 420px) {
    .premium-offer,
    .premium-feature {
        border-radius: 1.2rem;
    }

    .premium-offer {
        padding: 1.35rem;
    }

    .premium-feature {
        padding: 1.15rem;
    }

    .premium-plan-grid {
        grid-template-columns: 1fr;
    }

    .premium-plan-card {
        min-height: 6.45rem;
    }

    .premium-certificate--algorithms { --x: -3.9rem; }
    .premium-certificate--spring { --x: -2rem; }
    .premium-certificate--sql { --x: 2rem; }
    .premium-certificate--system { --x: 3.9rem; }
}
