:root {
    --deep-sea: #041b29;
    --panel: rgba(4, 35, 49, 0.82);
    --foam: #eefbf7;
    --muted: #b9d7d7;
    --sand: #e7c77a;
    --line: rgba(210, 240, 235, 0.24);
    --ocean-image: url("/assets/images/beijing.jpg");
}

* {
    box-sizing: border-box;
}

body {
    min-height: 100vh;
    margin: 0;
    padding: 32px 16px;
    display: grid;
    place-items: center;
    color: var(--foam);
    font-family: "Microsoft YaHei", "PingFang SC", "Segoe UI", sans-serif;
    background-color: var(--deep-sea);
    background-image:
        linear-gradient(155deg, rgba(2, 22, 34, 0.28), rgba(2, 22, 34, 0.86)),
        var(--ocean-image);
    background-position: center;
    background-size: cover;
    background-attachment: fixed;
}

main {
    width: min(680px, 100%);
    padding: 36px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--panel);
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.28);
    backdrop-filter: blur(14px);
}

h1 {
    margin: 0 0 12px;
    font-size: 2.25rem;
    line-height: 1.25;
}

p {
    color: var(--muted);
    line-height: 1.8;
}

.message {
    padding: 10px 14px;
    border: 1px solid var(--line);
    border-radius: 6px;
    color: var(--foam);
    background: rgba(255, 255, 255, 0.07);
}

.message.error {
    border-color: rgba(240, 160, 140, 0.7);
}

.message.success {
    border-color: rgba(137, 220, 185, 0.7);
}

form {
    margin-top: 24px;
}

label {
    display: block;
    margin-bottom: 10px;
    color: var(--foam);
    font-weight: 600;
}

textarea {
    width: 100%;
    min-height: 180px;
    padding: 14px;
    resize: vertical;
    color: var(--foam);
    font: inherit;
    line-height: 1.7;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.06);
}

textarea::placeholder {
    color: rgba(230, 248, 244, 0.5);
}

textarea:focus {
    outline: 2px solid var(--sand);
    outline-offset: 2px;
}

button,
main > a {
    display: inline-block;
    margin-top: 16px;
    padding: 11px 18px;
    color: #08232f;
    font: inherit;
    font-weight: 700;
    text-decoration: none;
    border: 0;
    border-radius: 6px;
    background: var(--sand);
    cursor: pointer;
}

button:hover,
main > a:hover {
    background: #f3dc9c;
}

a {
    color: var(--sand);
}

article {
    margin: 24px 0;
    padding-left: 18px;
    border-left: 3px solid var(--sand);
}

.bottle-text {
    color: var(--foam);
    font-size: 1.15rem;
    line-height: 1.9;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

@media (max-width: 560px) {
    body {
        padding: 16px;
    }

    main {
        padding: 24px 18px;
    }

    h1 {
        font-size: 1.9rem;
    }

    button {
        width: 100%;
    }
}.char-count {
    margin: 10px 0 0;
    font-size: 0.9rem;
}

.char-count.near-limit {
    color: #ffb89d;
}.easter-caption {
    color: var(--foam);
    font-size: 1.05rem;
}

.easter-image {
    display: block;
    width: 100%;
    max-width: 420px;
    max-height: 60vh;
    margin: 24px auto;
    object-fit: contain;
    border: 1px solid var(--line);
    border-radius: 8px;
}[hidden] {
    display: none !important;
}

.app-header {
    margin-bottom: 28px;
}

.eyebrow {
    margin: 0 0 8px;
    color: var(--sand);
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.08em;
}

.intro {
    max-width: 40ch;
}

.form-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-top: 10px;
}

.primary-button,
.secondary-button {
    margin: 0;
}

.secondary-button {
    width: 100%;
    color: var(--foam);
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.06);
}

.secondary-button:hover {
    background: rgba(255, 255, 255, 0.12);
}

.section-divider {
    margin: 26px 0 18px;
    color: var(--muted);
    font-size: 0.86rem;
    text-align: center;
    border-top: 1px solid var(--line);
}

.section-divider span {
    position: relative;
    top: -0.85em;
    padding: 0 10px;
    background: #082532;
}

.bottle-view {
    margin-top: 26px;
    padding-top: 24px;
    border-top: 1px solid var(--line);
}

.bottle-kicker {
    margin: 0;
    color: var(--sand);
    font-weight: 700;
}

.bottle-view .bottle-text {
    margin: 18px 0;
}

.bottle-time {
    font-size: 0.9rem;
}

.egg-dialog {
    width: min(460px, calc(100% - 32px));
    padding: 0;
    color: var(--foam);
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--panel);
}

.egg-dialog::backdrop {
    background: rgba(1, 12, 20, 0.78);
    backdrop-filter: blur(8px);
}

.egg-content {
    position: relative;
    padding: 28px;
}

.egg-content h2 {
    margin: 0 0 18px;
}

.icon-button {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 36px;
    height: 36px;
    margin: 0;
    padding: 0;
    color: var(--foam);
    font-size: 1.25rem;
    border: 1px solid var(--line);
    background: transparent;
}

.egg-image {
    display: block;
    width: 100%;
    max-height: 60vh;
    margin-bottom: 18px;
    object-fit: contain;
    border: 1px solid var(--line);
    border-radius: 6px;
}

@media (max-width: 560px) {
    .form-meta {
        align-items: stretch;
        flex-direction: column;
    }

    .primary-button,
    .secondary-button {
        width: 100%;
    }
}