@font-face {
    font-family: "Brandon Text";
    src: url("/fonts/brandon-text-thin.otf") format("opentype");
    font-weight: 100;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "Brandon Text";
    src: url("/fonts/brandon-text-thin-italic.otf") format("opentype");
    font-weight: 100;
    font-style: italic;
    font-display: swap;
}

@font-face {
    font-family: "Brandon Text";
    src: url("/fonts/brandon-text-light.otf") format("opentype");
    font-weight: 300;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "Brandon Text";
    src: url("/fonts/brandon-text-light-italic.otf") format("opentype");
    font-weight: 300;
    font-style: italic;
    font-display: swap;
}

@font-face {
    font-family: "Brandon Text";
    src: url("/fonts/brandon-text-regular.otf") format("opentype");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "Brandon Text";
    src: url("/fonts/brandon-text-regular-italic.otf") format("opentype");
    font-weight: 400;
    font-style: italic;
    font-display: swap;
}

@font-face {
    font-family: "Brandon Text";
    src: url("/fonts/brandon-text-medium.otf") format("opentype");
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "Brandon Text";
    src: url("/fonts/brandon-text-medium-italic.otf") format("opentype");
    font-weight: 500;
    font-style: italic;
    font-display: swap;
}

@font-face {
    font-family: "Brandon Text";
    src: url("/fonts/brandon-text-medium.otf") format("opentype");
    font-weight: 600;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "Brandon Text";
    src: url("/fonts/brandon-text-medium-italic.otf") format("opentype");
    font-weight: 600;
    font-style: italic;
    font-display: swap;
}

@font-face {
    font-family: "Brandon Text";
    src: url("/fonts/brandon-text-bold.otf") format("opentype");
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "Brandon Text";
    src: url("/fonts/brandon-text-bold-italic.otf") format("opentype");
    font-weight: 700;
    font-style: italic;
    font-display: swap;
}

@font-face {
    font-family: "Brandon Text";
    src: url("/fonts/brandon-text-black.otf") format("opentype");
    font-weight: 900;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "Brandon Text";
    src: url("/fonts/brandon-text-black-italic.otf") format("opentype");
    font-weight: 900;
    font-style: italic;
    font-display: swap;
}

*, *::before, *::after { box-sizing: border-box; }

[hidden] {
    display: none !important;
}

:root {
    font-family: "Brandon Text", "Segoe UI", Arial, sans-serif;
    --title-font: "Brandon Text", "Segoe UI", Arial, sans-serif;
    --bg: #f5f7f9;
    --bg-soft: #eef2f6;
    --primary: #475d77;
    --accent: #fbb760;
    --card-bg: #ffffff;
    --text: #475d77;
    --muted: #6c7b8d;
    --line: #e1e6ec;
    --danger: #991b1b;
    --danger-bg: #fee2e2;
    --success: #166534;
    --success-bg: #dcfce7;
    --warning-bg: #fff7e8;
    --radius: 10px;
}

body {
    margin: 0;
    min-height: 100vh;
    padding: 2.4rem 1rem;
    background: linear-gradient(180deg, var(--bg) 0%, var(--bg-soft) 100%);
    color: var(--text);
    display: flex;
    justify-content: center;
    align-items: flex-start;
}

main {
    position: relative;
    width: 100%;
    max-width: 620px;
    padding: 2.75rem 2.35rem;
    background: var(--card-bg);
    border: 1px solid rgba(225, 230, 236, 0.9);
    border-radius: 16px;
    box-shadow: 0 12px 34px rgba(71, 93, 119, 0.12);
}

main.admin-main,
main.is-secret-revealed {
    width: fit-content;
    max-width: min(1120px, calc(100vw - 2rem));
}

main.is-secret-revealed {
    min-width: min(920px, calc(100vw - 2rem));
}

.logo {
    display: block;
    width: 160px;
    height: auto;
    margin: 0 auto 1.45rem;
}

.language-flag {
    position: absolute;
    top: 1.05rem;
    right: 1.15rem;
    display: inline-block;
    width: 1.45rem;
    height: 0.96rem;
    line-height: 0;
    text-decoration: none;
    filter: drop-shadow(0 2px 3px rgba(71, 93, 119, 0.12));
    transition: transform 0.2s;
}

.language-flag img {
    display: block;
    width: 100%;
    height: 100%;
    border-radius: 2px;
    object-fit: cover;
}

.language-flag:hover {
    transform: translateY(-1px) scale(1.04);
}

.internal-menu {
    position: absolute;
    top: 1rem;
    left: 50%;
    right: auto;
    display: inline-flex;
    gap: 0.2rem;
    padding: 0.18rem;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.88);
    box-shadow: 0 5px 14px rgba(71, 93, 119, 0.1);
    transform: translateX(-50%);
}

.internal-menu ~ .logo {
    margin-top: 1.55rem;
}

.internal-menu a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 4.2rem;
    padding: 0.38rem 0.68rem;
    border-radius: 999px;
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 600;
    line-height: 1;
    text-decoration: none;
    transition: background 0.2s, color 0.2s, transform 0.2s;
}

.internal-menu a:hover {
    color: var(--primary);
    transform: translateY(-1px);
}

.internal-menu a.is-active {
    background: var(--primary);
    color: #fff;
}

h1 {
    margin: 0;
    color: var(--primary);
    font-size: 2rem;
    line-height: 1.18;
    font-weight: 300;
    text-align: center;
}

.subtitle {
    margin: 0.45rem 0 1.35rem;
    color: var(--muted);
    font-size: 0.95rem;
    text-align: center;
}

.page-title-row {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    margin: 0.45rem 0 1.35rem;
}

.page-title-row .subtitle {
    margin: 0;
}

.info-popover {
    position: relative;
    z-index: 5;
}

.info-popover summary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.35rem;
    height: 1.35rem;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #fff;
    color: var(--primary);
    font-size: 0.82rem;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(71, 93, 119, 0.1);
    list-style: none;
    user-select: none;
}

.info-popover summary::-webkit-details-marker {
    display: none;
}

.info-popover summary:hover,
.info-popover[open] summary {
    background: var(--primary);
    color: #fff;
}

.info-card {
    position: absolute;
    top: calc(100% + 0.55rem);
    right: 0;
    width: min(27rem, calc(100vw - 2rem));
    padding: 1rem 1.05rem;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    box-shadow: 0 16px 38px rgba(71, 93, 119, 0.18);
    color: var(--text);
    text-align: left;
}

.info-card h2 {
    margin-top: 0;
}

.info-card ul {
    margin: 0.55rem 0 0;
    padding-left: 1.15rem;
}

.info-card li {
    margin: 0.42rem 0;
    line-height: 1.45;
}

.info-card code {
    padding: 0.05rem 0.28rem;
    border-radius: 5px;
    background: var(--bg-soft);
    color: var(--primary);
    font-size: 0.9em;
}

h2 {
    margin: 1.45rem 0 0.6rem;
    color: var(--primary);
    font-size: 1.05rem;
    font-weight: 600;
}

p {
    margin: 0.45rem 0;
    color: var(--text);
    line-height: 1.55;
}

section {
    margin-top: 1.35rem;
}

form {
    margin: 0;
}

label {
    display: block;
    margin: 1rem 0 0.32rem;
    color: var(--text);
    font-weight: 600;
}

input,
textarea,
select {
    width: 100%;
    padding: 0.68rem 0.85rem;
    border: 1px solid #cfd8e3;
    border-radius: var(--radius);
    background: #fff;
    color: var(--text);
    font: inherit;
    font-size: 1rem;
}

textarea {
    min-height: 7rem;
    resize: vertical;
    line-height: 1.45;
}

input:focus,
textarea:focus,
select:focus {
    outline: 2px solid var(--accent);
    border-color: var(--accent);
}

button {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    padding: 0.78rem 1rem;
    border: 0;
    border-radius: var(--radius);
    background: var(--accent);
    color: #fff;
    font: inherit;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, transform 0.2s;
    box-shadow: 0 5px 14px rgba(251, 183, 96, 0.24);
}

button:hover {
    background: var(--primary);
    transform: translateY(-1px);
}

form > button[type="submit"] {
    width: 100%;
    margin-top: 1.25rem;
}

#decrypt-form .secret-status {
    margin: 1rem 0;
}

#decrypt-form > button[type="submit"] {
    margin-top: 0;
}

button[type="button"] {
    white-space: nowrap;
}

fieldset {
    margin-top: 1.25rem;
    padding: 1rem 1.1rem 1.1rem;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
}

legend {
    padding: 0 0.25rem;
    color: var(--primary);
    font-size: 1rem;
    font-weight: 600;
}

.checkbox-row {
    display: flex;
    gap: 0.65rem;
    align-items: flex-start;
    margin: 0.75rem 0 0.6rem;
}

.checkbox-row input[type="checkbox"] {
    width: auto;
    margin: 0.22rem 0 0;
    accent-color: var(--accent);
}

.checkbox-row span {
    line-height: 1.4;
}

.expiry-row {
    display: grid;
    grid-template-columns: 92px 1fr auto;
    gap: 0.55rem;
    align-items: center;
    margin-top: 0.75rem;
}

.expiry-row label {
    margin: 0;
    color: var(--muted);
    font-size: 0.9rem;
}

.expiry-row select {
    min-width: 7.5rem;
}

.expiry-row input:last-child {
    grid-column: 2 / 4;
}

.copy-row {
    display: flex;
    gap: 0.55rem;
    align-items: stretch;
    margin-top: 0.25rem;
}

.copy-row input,
.copy-row textarea {
    flex: 1;
}

.copy-row textarea {
    min-height: 7rem;
    overflow: hidden;
    resize: none;
}

main.is-secret-revealed .secret-copy-row {
    position: relative;
    display: block;
}

main.is-secret-revealed .secret-copy-row .copy-icon-button {
    position: absolute;
    top: 0.55rem;
    right: 0.55rem;
    z-index: 2;
    background: rgba(255, 255, 255, 0.88);
    backdrop-filter: blur(4px);
}

main.is-secret-revealed .secret-copy-row .copy-icon-button:hover,
main.is-secret-revealed .secret-copy-row .copy-icon-button:focus-visible,
main.is-secret-revealed .secret-copy-row .copy-icon-button.is-copied {
    background: var(--warning-bg);
}

.secret-code {
    min-height: 12rem;
    overflow: auto;
    resize: vertical;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    letter-spacing: normal;
    line-height: 1.45;
    tab-size: 4;
}

.editor-mode {
    display: flex;
    justify-content: flex-end;
    margin: 0.1rem 0 0.35rem;
}

.icon-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 2rem;
    height: 2rem;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: var(--primary);
    box-shadow: none;
    font-size: 0.95rem;
    font-weight: 700;
    line-height: 1;
}

.icon-button:hover,
.icon-button:focus-visible {
    background: var(--warning-bg);
    transform: none;
}

.icon-button:focus-visible {
    outline: 2px solid rgba(251, 183, 96, 0.85);
    outline-offset: 2px;
}

.toolbar-icon {
    display: inline-block;
    width: 1.05rem;
    height: 1.05rem;
    color: currentColor;
    background-color: currentColor;
    mask-position: center;
    mask-repeat: no-repeat;
    mask-size: contain;
    -webkit-mask-position: center;
    -webkit-mask-repeat: no-repeat;
    -webkit-mask-size: contain;
}

.toolbar-icon-link {
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M10.6 13.4a1.4 1.4 0 0 1 0-2l3.6-3.6a3 3 0 1 1 4.2 4.2l-3.2 3.2a3 3 0 0 1-4.1.1l1.4-1.4a1 1 0 0 0 1.3-.1L17 10.6a1 1 0 0 0-1.4-1.4L12 12.8a1.4 1.4 0 0 1-1.4.6ZM13.4 10.6a1.4 1.4 0 0 1 0 2l-3.6 3.6a3 3 0 1 1-4.2-4.2l3.2-3.2a3 3 0 0 1 4.1-.1l-1.4 1.4a1 1 0 0 0-1.3.1L7 13.4a1 1 0 0 0 1.4 1.4l3.6-3.6a1.4 1.4 0 0 1 1.4-.6Z'/%3E%3C/svg%3E");
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M10.6 13.4a1.4 1.4 0 0 1 0-2l3.6-3.6a3 3 0 1 1 4.2 4.2l-3.2 3.2a3 3 0 0 1-4.1.1l1.4-1.4a1 1 0 0 0 1.3-.1L17 10.6a1 1 0 0 0-1.4-1.4L12 12.8a1.4 1.4 0 0 1-1.4.6ZM13.4 10.6a1.4 1.4 0 0 1 0 2l-3.6 3.6a3 3 0 1 1-4.2-4.2l3.2-3.2a3 3 0 0 1 4.1-.1l-1.4 1.4a1 1 0 0 0-1.3.1L7 13.4a1 1 0 0 0 1.4 1.4l3.6-3.6a1.4 1.4 0 0 1 1.4-.6Z'/%3E%3C/svg%3E");
}

.toolbar-icon-list {
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M5 7a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Zm4-2h11v2H9V5Zm-4 8a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Zm4-2h11v2H9v-2Zm-4 8a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Zm4-2h11v2H9v-2Z'/%3E%3C/svg%3E");
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M5 7a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Zm4-2h11v2H9V5Zm-4 8a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Zm4-2h11v2H9v-2Zm-4 8a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Zm4-2h11v2H9v-2Z'/%3E%3C/svg%3E");
}

.toolbar-icon-copy {
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M8 7a3 3 0 0 1 3-3h6a3 3 0 0 1 3 3v6a3 3 0 0 1-3 3h-1v1a3 3 0 0 1-3 3H7a3 3 0 0 1-3-3v-6a3 3 0 0 1 3-3h1V7Zm2 1h3a3 3 0 0 1 3 3v3h1a1 1 0 0 0 1-1V7a1 1 0 0 0-1-1h-6a1 1 0 0 0-1 1v1Zm-3 2a1 1 0 0 0-1 1v6a1 1 0 0 0 1 1h6a1 1 0 0 0 1-1v-6a1 1 0 0 0-1-1H7Z'/%3E%3C/svg%3E");
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M8 7a3 3 0 0 1 3-3h6a3 3 0 0 1 3 3v6a3 3 0 0 1-3 3h-1v1a3 3 0 0 1-3 3H7a3 3 0 0 1-3-3v-6a3 3 0 0 1 3-3h1V7Zm2 1h3a3 3 0 0 1 3 3v3h1a1 1 0 0 0 1-1V7a1 1 0 0 0-1-1h-6a1 1 0 0 0-1 1v1Zm-3 2a1 1 0 0 0-1 1v6a1 1 0 0 0 1 1h6a1 1 0 0 0 1-1v-6a1 1 0 0 0-1-1H7Z'/%3E%3C/svg%3E");
}

.toolbar-icon-delete {
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M9 3h6l1 2h4v2H4V5h4l1-2Zm-2.2 6h10.4l-.8 10.2A3 3 0 0 1 13.4 22H10.6a3 3 0 0 1-3-2.8L6.8 9Zm2.1 2 .6 8a1 1 0 0 0 1 .9h2.9a1 1 0 0 0 1-.9l.6-8H8.9Zm1.1 1.5h1.8v5H10v-5Zm4.2 0H16v5h-1.8v-5Z'/%3E%3C/svg%3E");
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M9 3h6l1 2h4v2H4V5h4l1-2Zm-2.2 6h10.4l-.8 10.2A3 3 0 0 1 13.4 22H10.6a3 3 0 0 1-3-2.8L6.8 9Zm2.1 2 .6 8a1 1 0 0 0 1 .9h2.9a1 1 0 0 0 1-.9l.6-8H8.9Zm1.1 1.5h1.8v5H10v-5Zm4.2 0H16v5h-1.8v-5Z'/%3E%3C/svg%3E");
}

.copy-icon-button {
    position: relative;
    flex: 0 0 auto;
    align-self: center;
    color: var(--muted);
}

.copy-icon-button:hover,
.copy-icon-button:focus-visible,
.copy-icon-button.is-copied {
    color: var(--primary);
}

.copy-icon-button.is-copied .toolbar-icon-copy {
    animation: copy-icon-pop 0.72s cubic-bezier(0.18, 0.9, 0.22, 1) both;
}

.copy-icon-button.is-copied::after {
    content: "";
    position: absolute;
    inset: 0.18rem;
    border-radius: 999px;
    border: 2px solid currentColor;
    pointer-events: none;
    animation: copy-icon-ripple 0.72s ease-out both;
}

@keyframes copy-icon-pop {
    0% {
        transform: scale(1);
    }
    38% {
        transform: scale(0.82) rotate(-6deg);
    }
    70% {
        transform: scale(1.18) rotate(4deg);
    }
    100% {
        transform: scale(1) rotate(0);
    }
}

@keyframes copy-icon-ripple {
    0% {
        opacity: 0.42;
        transform: scale(0.72);
    }
    100% {
        opacity: 0;
        transform: scale(1.55);
    }
}

.copy-icon-button.is-copy-error {
    color: var(--danger);
}

.editor-mode-toggle {
    min-width: 2.25rem;
    height: 1.7rem;
    font-size: 0.72rem;
    letter-spacing: 0.04em;
}

.markdown-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.22rem;
    margin: 0 0 0.45rem;
}

.markdown-toolbar[hidden] {
    display: none;
}

.markdown-content {
    padding: 0.85rem 1rem;
    border: 0;
    border-radius: var(--radius);
    background: #fff;
    color: var(--text);
    line-height: 1.5;
    overflow: auto;
    overflow-wrap: anywhere;
    tab-size: 4;
}

.markdown-content[hidden] {
    display: none;
}

.markdown-editor {
    min-height: 12rem;
    border: 1px solid rgba(71, 93, 119, 0.22);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.55);
    outline: none;
    resize: vertical;
}

.markdown-editor::after {
    content: "";
    display: block;
    min-height: 1.5em;
}

.markdown-editor:focus {
    border-color: rgba(251, 183, 96, 0.85);
    box-shadow: 0 0 0 3px rgba(251, 183, 96, 0.18);
}

.markdown-editor:empty::before {
    content: attr(data-placeholder);
    color: var(--muted);
    pointer-events: none;
}

.secret-rendered {
    min-height: 12rem;
    border: 1px solid var(--line);
    box-shadow: 0 10px 24px rgba(71, 93, 119, 0.08);
}

main.is-secret-revealed .secret-rendered {
    padding-right: 3.05rem;
}

main.is-secret-revealed #secret-display {
    padding-right: 3.05rem;
    border-color: var(--line);
    box-shadow: 0 10px 24px rgba(71, 93, 119, 0.08);
}

.markdown-content h1,
.markdown-content h2,
.markdown-content h3 {
    margin: 1rem 0 0.45rem;
    color: var(--primary);
    font-family: var(--title-font);
    font-weight: 300;
    letter-spacing: 0.01em;
    line-height: 1.18;
    text-align: left;
}

.markdown-content h1 {
    font-size: 1.75rem;
}

.markdown-content h2 {
    font-size: 1.38rem;
}

.markdown-content h3 {
    font-size: 1.12rem;
}

.markdown-content h1:first-child,
.markdown-content h2:first-child,
.markdown-content h3:first-child,
.markdown-content p:first-child,
.markdown-content ul:first-child,
.markdown-content blockquote:first-child,
.markdown-content pre:first-child {
    margin-top: 0;
}

.markdown-content p,
.markdown-content ul {
    margin: 0.45rem 0;
}

.markdown-content a {
    color: var(--primary);
    font-weight: 600;
}

.markdown-content pre,
.markdown-content code {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

.markdown-content code {
    padding: 0.1rem 0.28rem;
    border-radius: 0.35rem;
    background: var(--bg-soft);
}

.markdown-content pre {
    padding: 0.75rem;
    border-radius: var(--radius);
    background: var(--bg-soft);
    overflow-x: auto;
    white-space: pre-wrap;
}

.markdown-content pre code {
    padding: 0;
    background: transparent;
}

.markdown-content blockquote {
    margin: 0.8rem 0;
    padding-left: 0.8rem;
    border-left: 4px solid var(--accent);
    color: var(--muted);
}

.field-hint {
    margin: 0.45rem 0 0;
    color: var(--muted);
    font-size: 0.82rem;
    line-height: 1.35;
}

.mono {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    letter-spacing: 0.04em;
}

.warning,
.error,
.notes-box {
    margin: 0.75rem 0;
    padding: 0.85rem 1rem;
    border-radius: var(--radius);
    line-height: 1.45;
}

.warning {
    border: 1px solid rgba(251, 183, 96, 0.55);
    background: var(--warning-bg);
    color: var(--text);
}

.error {
    border: 1px solid #fca5a5;
    background: var(--danger-bg);
    color: var(--danger);
}

.notes-box {
    border-left: 4px solid var(--accent);
    background: #f5f7f9;
    box-shadow: inset 0 0 0 1px rgba(225, 230, 236, 0.75);
}

.expiry-info,
.warning-inline {
    color: var(--muted);
    font-size: 0.84rem;
    line-height: 1.35;
}

.warning-inline {
    font-weight: 400;
}

.secret-status {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
    margin: 1rem 0 1.1rem;
}

.secret-status[hidden] {
    display: none;
}

.secret-status-item {
    padding: 0.85rem 0.95rem;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    box-shadow: inset 0 0 0 1px rgba(225, 230, 236, 0.45);
}

.secret-status-label,
.secret-status-sub {
    display: block;
    color: var(--muted);
    font-size: 0.78rem;
    line-height: 1.3;
}

.secret-status-value {
    display: block;
    margin: 0.15rem 0;
    color: var(--primary);
    font-size: 1.55rem;
    line-height: 1.1;
    font-weight: 600;
}

.number-slide {
    display: inline-flex;
    align-items: baseline;
    min-height: 1.72rem;
    overflow: hidden;
    font-variant-numeric: tabular-nums;
}

.number-slide-char {
    position: relative;
    display: inline-block;
    width: auto;
    height: 1.12em;
    overflow: hidden;
    line-height: 1.12;
    text-align: center;
    vertical-align: bottom;
}

.number-slide-char.is-digit {
    min-width: 0.62em;
}

.number-slide-char.is-unit {
    min-width: 0.42em;
}

.number-slide-char.is-static {
    overflow: visible;
}

.number-slide-char.is-space {
    min-width: 0.22em;
}

.number-slide-old,
.number-slide-new {
    display: block;
    will-change: transform, opacity;
}

.number-slide-char:not(.is-static) .number-slide-old {
    animation: number-slide-old 0.52s cubic-bezier(0.22, 0.78, 0.24, 1) both;
}

.number-slide-char:not(.is-static) .number-slide-new {
    position: absolute;
    inset: 0;
    animation: number-slide-new 0.52s cubic-bezier(0.22, 0.78, 0.24, 1) both;
}

.secret-status-item.is-expiry {
    border-left: 4px solid var(--accent);
}

.secret-status-item.is-views {
    border-left: 4px solid var(--primary);
}

.secret-status-item.is-warning {
    border-left: 4px solid var(--accent);
    background: var(--warning-bg);
}

.secret-status-item.is-danger {
    border-left: 4px solid #991b1b;
    background: var(--danger-bg);
}

.secret-status-item.is-success {
    border-left: 4px solid var(--success);
    background: var(--success-bg);
}

.secret-status-item.is-success .secret-status-value {
    color: var(--success);
}

.secret-status-item.is-expiry,
.secret-status-item.is-expiry-urgent,
.secret-status-item.is-expiry-critical {
    position: relative;
    overflow: hidden;
}

.secret-status-item.is-expiry-urgent {
    border-color: rgba(251, 183, 96, 0.85);
    box-shadow: 0 12px 30px rgba(251, 183, 96, 0.22);
}

.secret-status-item.is-expiry-critical {
    border-color: rgba(153, 27, 27, 0.55);
    box-shadow: 0 14px 34px rgba(153, 27, 27, 0.18);
}

.secret-status-item.is-expiry-critical .secret-status-value {
    color: #991b1b;
}

.secret-status-item.is-expiry-critical {
    animation: countdown-pulse 1s ease-in-out infinite;
}

@keyframes countdown-pulse {
    0%, 100% { filter: saturate(1); }
    50% { filter: saturate(1.18); }
}

@keyframes number-slide-old {
    from {
        opacity: 1;
        transform: translateY(0);
    }
    to {
        opacity: 0;
        transform: translateY(115%);
    }
}

@keyframes number-slide-new {
    from {
        opacity: 0;
        transform: translateY(-115%);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

#create-section,
#key-section,
#confirm-section,
#error-section,
#admin-section {
    border-top: 1px solid var(--line);
    padding-top: 1.2rem;
}

#secret-section {
    padding-top: 0;
}

.admin-toolbar {
    display: flex;
    gap: 1rem;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.admin-toolbar p {
    margin: 0;
}

.refresh-icon {
    width: 2.25rem;
    height: 2.25rem;
    padding: 0;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #fff;
    color: var(--primary);
    box-shadow: 0 5px 14px rgba(71, 93, 119, 0.1);
}

.refresh-icon svg {
    width: 1.1rem;
    height: 1.1rem;
    fill: currentColor;
}

.refresh-icon:hover {
    background: #fff;
    border-color: var(--accent);
}

.refresh-icon.is-refreshing svg {
    animation: refresh-spin 0.75s linear infinite;
}

.refresh-icon:disabled {
    cursor: wait;
    opacity: 0.8;
}

@keyframes refresh-spin {
    to { transform: rotate(360deg); }
}

.secret-list {
    margin-top: 1rem;
}

.admin-table-wrap {
    overflow-x: auto;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
}

.admin-table {
    width: auto;
    min-width: 0;
    border-collapse: collapse;
    font-size: 0.88rem;
}

.admin-table th,
.admin-table td {
    padding: 0.45rem 0.52rem;
    border-bottom: 1px solid var(--line);
    text-align: left;
    vertical-align: middle;
    white-space: nowrap;
}

.admin-table th {
    color: var(--primary);
    font-weight: 600;
    background: #f5f7f9;
}

.admin-table tbody tr:last-child td {
    border-bottom: 0;
}

.admin-table tbody tr.is-new-secret {
    animation: new-secret-row 1.8s ease-out;
}

.admin-table tbody tr.is-new-secret td {
    background: rgba(251, 183, 96, 0.18);
}

@keyframes new-secret-row {
    0% {
        filter: saturate(1.18);
        transform: translateY(-0.35rem);
    }
    35% {
        box-shadow: inset 4px 0 0 var(--accent);
        transform: translateY(0);
    }
    100% {
        filter: saturate(1);
        box-shadow: inset 4px 0 0 rgba(251, 183, 96, 0);
    }
}

.note-cell {
    min-width: 8rem;
    max-width: 14rem;
    overflow: hidden;
    text-overflow: ellipsis;
}

.admin-table [data-field="createdAt"],
.admin-table [data-field="expiresAt"] {
    width: 9.4rem;
}

.admin-table [data-field="timer"] {
    width: 5.2rem;
}

.admin-table [data-field="views"] {
    width: 3.8rem;
}

.admin-table [data-field="status"] {
    width: 5.2rem;
}

.admin-expiry-timer {
    display: inline-block;
    position: relative;
    min-width: 4.5rem;
    min-height: 1.15rem;
    overflow: hidden;
    color: var(--primary);
    font-weight: 600;
}

.admin-expiry-timer.is-soon {
    color: #b45309;
}

.admin-expiry-timer.is-expired {
    color: #991b1b;
}

.action-col {
    width: 2.5rem;
    text-align: right !important;
}

.delete-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    border-radius: 999px;
    color: var(--muted);
    line-height: 1;
    text-decoration: none;
    transition: background 0.2s, color 0.2s, transform 0.2s;
}

.delete-icon:hover,
.delete-icon:focus-visible {
    background: var(--danger-bg);
    color: var(--danger);
    transform: scale(1.06);
}

.delete-icon:focus-visible {
    outline: 2px solid rgba(153, 27, 27, 0.32);
    outline-offset: 2px;
}

.delete-icon[aria-disabled="true"] {
    pointer-events: none;
    opacity: 0.55;
}

#new-secret {
    width: 100%;
    margin-top: 1rem;
}

@media (prefers-reduced-motion: reduce) {
    .number-slide-old,
    .number-slide-new,
    .admin-table tbody tr.is-new-secret,
    .secret-status-item.is-expiry-critical,
    .refresh-icon.is-refreshing svg {
        animation: none;
    }

    .number-slide-char:not(.is-static) .number-slide-new {
        position: static;
    }

    .number-slide-char:not(.is-static) .number-slide-old {
        display: none;
    }
}

@media (max-width: 560px) {
    body { padding: 1rem; }
    main { padding: 4.15rem 1.35rem 2rem; }
    h1 { font-size: 1.72rem; }
    .expiry-row { grid-template-columns: 1fr; }
    .expiry-row input:last-child { grid-column: auto; }
    .secret-status { grid-template-columns: 1fr; }
    .copy-row { flex-direction: column; }
    .copy-row button:not(.copy-icon-button) { width: 100%; }
    .copy-row .copy-icon-button { align-self: flex-end; }
    .admin-toolbar { align-items: stretch; flex-direction: column; }
    .admin-table { width: max-content; max-width: none; }
}
