.codex-browser-shell {
    position: fixed;
    inset: 0;
    z-index: 40;
    pointer-events: none;
    font-family: "Malgun Gothic", Gulim, "Apple SD Gothic Neo", "Noto Sans KR", sans-serif;
}

.codex-browser-shell::before {
    content: "";
    position: absolute;
    inset: 0;
    opacity: 0;
    background:
        linear-gradient(180deg, rgba(238, 245, 251, 0.78) 0%, rgba(221, 231, 244, 0.9) 100%);
    backdrop-filter: blur(10px);
    transition: opacity 0.18s ease;
}

.codex-browser-shell[data-block-pointer="true"] {
    pointer-events: auto;
}

.codex-browser-shell[data-block-pointer="true"]::before {
    opacity: 1;
}

.codex-browser-shell__card {
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid rgba(180, 196, 216, 0.92);
    border-radius: 28px;
    box-shadow: 0 20px 42px rgba(54, 74, 98, 0.18);
    backdrop-filter: blur(12px);
    position: relative;
    z-index: 1;
}

.codex-browser-shell__menu,
.codex-browser-shell__modal {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: min(540px, calc(100vw - 48px));
    padding: 30px 34px;
    text-align: center;
    pointer-events: auto;
}

.codex-browser-shell__menu[hidden],
.codex-browser-shell__hud[hidden],
.codex-browser-shell__center[hidden],
.codex-browser-shell__toast[hidden],
.codex-browser-shell__modal[hidden] {
    display: none !important;
}

.codex-browser-shell__kicker {
    margin: 0;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.28em;
    color: #4e6580;
}

.codex-browser-shell__title {
    margin: 12px 0 0;
    font-size: clamp(32px, 3.1vw, 42px);
    line-height: 1.2;
    letter-spacing: -0.045em;
    color: #223247;
}

.codex-browser-shell__subtitle,
.codex-browser-shell__modal-body {
    margin: 14px 0 0;
    font-size: 19px;
    line-height: 1.7;
    font-weight: 700;
    color: #415368;
}

.codex-browser-shell__controls {
    margin: 18px 0 0;
    padding: 16px 18px;
    border-radius: 20px;
    background: #eef4fb;
    color: #31445b;
    font-size: 17px;
    line-height: 1.65;
    font-weight: 700;
}

.codex-browser-shell__hud {
    position: absolute;
    top: 24px;
    left: 24px;
    right: 160px;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    gap: 12px;
    align-items: start;
}

.codex-browser-shell__content {
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
}

.codex-browser-shell__content[hidden] {
    display: none !important;
}

.codex-browser-shell__block {
    position: absolute;
    white-space: pre-line;
    overflow-wrap: anywhere;
    word-break: keep-all;
    pointer-events: none;
    box-sizing: border-box;
    font-family: "Malgun Gothic", "맑은 고딕", Gulim, "Apple SD Gothic Neo", "Noto Sans KR", sans-serif;
    -webkit-font-smoothing: antialiased;
    text-rendering: geometricPrecision;
    letter-spacing: -0.035em;
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.12);
}

.codex-browser-shell__hud-column {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: flex-start;
}

.codex-browser-shell__hud-column--right {
    justify-content: flex-end;
}

.codex-browser-shell__chip {
    display: inline-flex;
    align-items: center;
    min-height: 48px;
    padding: 0 18px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid rgba(180, 196, 216, 0.92);
    color: #24374a;
    font-size: 19px;
    font-weight: 800;
    letter-spacing: -0.03em;
    box-shadow: 0 10px 22px rgba(49, 69, 94, 0.12);
}

.codex-browser-shell__center {
    min-height: 52px;
    padding: 0 22px;
    border-radius: 999px;
    background: rgba(28, 48, 72, 0.92);
    color: #f6fbff;
    font-size: 20px;
    font-weight: 800;
    letter-spacing: -0.03em;
    box-shadow: 0 12px 28px rgba(26, 40, 58, 0.22);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.codex-browser-shell__toast {
    position: absolute;
    left: 50%;
    bottom: 28px;
    transform: translateX(-50%);
    z-index: 1;
    min-width: 280px;
    max-width: min(480px, calc(100vw - 48px));
    padding: 16px 22px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid rgba(184, 201, 220, 0.96);
    color: #23364a;
    font-size: 20px;
    font-weight: 800;
    letter-spacing: -0.03em;
    text-align: center;
    box-shadow: 0 14px 28px rgba(57, 77, 101, 0.14);
}

.codex-browser-shell__modal-lines {
    margin: 18px 0 0;
    padding: 16px 18px;
    border-radius: 20px;
    background: #f2f6fb;
    color: #31445b;
    font-size: 17px;
    line-height: 1.6;
    font-weight: 700;
}

.codex-browser-shell__modal-lines:empty {
    display: none;
}

.codex-browser-shell__modal-actions {
    margin-top: 24px;
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}

.codex-browser-shell__primary,
.codex-browser-shell__secondary {
    min-width: 154px;
    min-height: 56px;
    border-radius: 999px;
    border: 0;
    font-size: 21px;
    font-weight: 800;
    letter-spacing: -0.03em;
    cursor: pointer;
    transition: transform 0.12s ease;
    font-family: inherit;
}

.codex-browser-shell__primary:hover,
.codex-browser-shell__secondary:hover {
    transform: translateY(-1px);
}

.codex-browser-shell__primary {
    padding: 0 26px;
    color: #1e2b38;
    background: linear-gradient(180deg, #ffd96b 0%, #f4bf3d 100%);
    box-shadow: 0 12px 26px rgba(183, 138, 19, 0.26);
}

.codex-browser-shell__secondary {
    padding: 0 24px;
    color: #26374a;
    background: #e8eef6;
    box-shadow: inset 0 0 0 1px rgba(113, 134, 160, 0.35);
}
