@font-face {
    font-family: 'depixelKlein';
    src: url('../assets/fonts/depixel/DePixelKlein.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'depixelHalbfett';
    src: url('../assets/fonts/depixel/DePixelHalbfett.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'pixel32';
    src: url('../assets/fonts/pix32/Pix32.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'BrotherSignature';
    src: url('../assets/fonts/brother_signature/Brother-Signature.otf') format('opentype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --paper: #fbf6ec;
    --paper-edge: #e9dfce;
    --ink: #4d4237;
    --ink-soft: #6b6154;
    --accent: #b4522f;
    --accent-deep: #8f3f23;
    --line: #cfc3ad;
    --shadow: rgba(58, 51, 43, 0.22);
}

::selection {
    background-color: rgb(169, 161, 174);
    color: #ffffff;
  }

::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-thumb {
    background: rgb(150, 146, 175);
    border-radius: 3px;
}

::-webkit-scrollbar-track {
    background: rgb(255, 255, 255);
}

body {
    color: var(--accent-deep);
    background-color: rgb(251, 224, 224);
    min-height: 100vh;
    padding: 32px 20px;
    background-repeat: repeat;
    background-position: center;
    flex-wrap: wrap;
}

h1, h2, h3, h4 {
    font-family: 'depixelHalbfett', 'pixel32';
}

p {
    font-family: 'depixelKlein', 'pixel32';
}

.page-footer {
    font-family: 'depixelKlein', 'pixel32';
    text-align: center;
    margin-top: 24px;
    color: var(--ink-soft);
    font-size:12px;
}

.top-sticker {
    position: absolute;
    top: 150px;
    left: 10%;
    transform: translateX(-90%) rotate(-40deg);
    object-fit: contain;
    z-index: 3;
    filter: drop-shadow(1px 2px 2px rgba(0, 0, 0, 0.12));
}

.sticker-stamp {
    position: absolute;
    top: 320px;
    right: 250px;
    transform: translateX(-90%) rotate(45deg);
    object-fit: contain;
    z-index: -1;
    filter: drop-shadow(1px 2px 2px rgba(0, 0, 0, 0.12));
}

.bottom-envelope {
    position: absolute;
    top: 0;
    right: -100px;
    transform: translateX(-50%) rotate(25deg);
    object-fit: contain;
    z-index: -2;
    filter: drop-shadow(1px 2px 2px rgba(0, 0, 0, 0.12));
}

.top {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 12px;
}

.blythe-doll {
    position: fixed;
    z-index: 99;
    top: 83.5%;
}

.blythe-doll img {
    transition: transform 300ms ease, box-shadow 300ms ease;
}

.blythe-doll img:hover {
    transform: translateY(-8px);
}

.postcard {
    position: relative;
    width: 650px;
    height: 360px;
    background-color: #fffef8;
    border-radius: 2px;
    box-shadow: 0 10px 10px rgba(0, 0, 0, 0.2);
    background-image: url('../assets/resources/background/wallpaper-001.png');
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.postcard:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 35px rgba(0, 0, 0, 0.22);
}

.postcard::before {
    content: "";
    position: absolute;
    top: 24px;
    bottom: 24px;
    right: 240px;
    width: 1px;
    background-image: linear-gradient(to bottom, #888 60%, transparent 40%);
    background-size: 100% 8px;
    opacity: 0.55;
}

.card-left {
    flex: 1 1 58%;
    padding: 46px 40px 40px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.card-left header h1 {
    letter-spacing: 2px;
    line-height: 1.15;
    color: #6b6154;
}

.card-left header .sub {
    margin-top: 12px;
    font-size: 15px;
    letter-spacing: 0.3em;
    color: var(--ink-soft);
}

.card-left .msg {
    margin: 30px 0 34px;
    font-size: 16px;
    line-height: 2.05;
    color: var(--ink);
    max-width: 44ch;
}
.card-left .msg b { color: var(--accent); font-weight: 600; }

.card-left footer {
    display: flex;
    align-items: baseline;
    gap: 10px;
    font-size: 13px;
    color: var(--ink-soft);
    letter-spacing: 0.08em;
    font-family: 'depixelKlein', 'pixel32';
}
.card-left footer .rule { flex: 1; height: 1px; background: var(--line); }

.stamp-row {
    position: relative;
}

.stamp-img {
    position: absolute;
    top:0;
    right:0;
    width:130px;
    object-fit: contain;
    filter: drop-shadow(2px 2px 3px rgba(0,0,0,0.15));
}

.card-right {
    flex: 1 1 42%;
    padding: 30px 60px 40px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
}

.postmark {
    margin-top: 36px;
    transform: rotate(-8deg);
    color: rgba(143,63,35,0.85);
    text-align: center;
}
.postmark .ring {
    font-size: 11px;
    letter-spacing: 0.12em;
    border: 1px solid currentColor;
    border-radius: 50%;
    width: 92px; height: 92px;
    display: flex; align-items: center; justify-content: center;
    opacity: 0.75;
}
.postmark .ring span { transform: rotate(-30deg); letter-spacing: 0.2em; }

.address {
    margin-top: 26px;
    display: flex;
    flex-direction: column;
    gap: 14px;
    font-family: 'depixelKlein', 'pixel32';
}

.address .field {
    font-size: 14px;
    color: var(--ink);
    letter-spacing: 2px;
}

.address .field .lbl {
    font-size: 10px;
    color: var(--ink-soft);
    letter-spacing: 2px;
    text-transform: uppercase;
}

.address .line {
    border-bottom: 1px dashed var(--line);
    padding-bottom: 2px;
}

.links {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 18px;
    margin-top: 26px;
    font-family: 'depixelKlein', 'pixel32';
}

.links a {
    color: #cfc3ad;
    text-decoration: var(--accent-deep) underline wavy;
    text-underline-offset: 2px;
    font-size: 13px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: color 0.2s ease;
}

.links a:hover {
    color: var(--accent);
    text-decoration: var(--accent-deep) underline wavy;
}

.links a svg {
    width: 15px;
    height: 15px;
    flex: none;
}

.ticker {
    width: 650px;
    margin: 100px auto 0 auto;
    overflow: hidden;
    padding: 4px;
    border: 2px dashed var(--shadow);
}

.ticker-track {
    display: flex;
    width: max-content;
    white-space: nowrap;
    animation: tickerMove 16s linear infinite;
    will-change: transform;
}

.ticker-track > span {
    padding: 0 15px;
}

.ticker-track a {
    color: #8f3f23;
    text-decoration: var(--accent-deep) underline wavy;
    text-underline-offset: 2px;
}

.ticker:hover .ticker-track {
    animation-play-state: paused;
}

@keyframes tickerMove {
    from {
        transform: translateX(0);
    }
    to {
        transform: translateX(-50%);
    }
}

.border-lace {
    border: var(--border-width) solid transparent;
    --border-width: 50px;
    border-image: url("../assets/resources/border/lace-white.png") 900 fill round;
    margin: var(--border-width);
    border-image-slice: 84;
    border-image-repeat: round;
    width: 850px;
    margin: 5px auto 0 auto;
}

.extra-panel {
    background-color: #fffef8;
    padding: 24px 28px;
}

.panel-header {
    position: relative;
    text-align: center;
}

.panel-header h2 {
    font-size: 24px;
    margin: 16px;
    color: var(--accent-deep);
    letter-spacing: 10px;
    position: relative;
    z-index: 2;
}

.header-sticker {
    position: absolute;
    z-index: 2;
    top: -25px;
    left: 10px;
    transform: rotate(-12deg);
    filter: drop-shadow(1px 2px 2px rgba(0,0,0,0.2));
    pointer-events: none;
}

.nav {
    display: flex;
    gap: 16px;
    margin-bottom: 16px;
    font-family: 'depixelKlein','pixel21';
    letter-spacing: 2px;
}

.nav a {
    color: #cfc3ad;
    text-decoration: var(--accent-deep) underline wavy;
    text-underline-offset: 2.5px;
    font-size: 13px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: color 0.2s ease;
}

.nav a:hover {
    color: var(--accent-deep);
}

.text-block {
    font-family: 'depixelKlein', 'pixel32';
    font-size: 15px;
    line-height: 1.8;
    color: var(--ink);
    margin-top: 20px;
}


/* .iframe-wrap iframe {
    width: 60%;
    min-height: 320px;
    border: 1px solid var(--line);
    border-radius: 2px;
    background-color: var(--paper);
}

.iframe-nav {
    display: flex;
    gap: 16px;
    margin-bottom: 16px;
    font-family: 'depixelKlein','pixel21';
    letter-spacing: 2px;
}

.iframe-nav a {
    color: #cfc3ad;
    text-decoration: var(--accent-deep) underline wavy;
    text-underline-offset: 2.5px;
    font-size: 13px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: color 0.2s ease;
}

.iframe-nav a:hover {
    color: var(--accent-deep);
} */

@media (max-width: 660px) {
    .postcard {
        width: 90vw;
        height: auto;
        min-height: 480px;
        flex-direction: column;
    }
    .postcard::before, .postcard::after {
        display: none;
    }
    .card-left,.card-right {
        flex: none;
        padding:24px;
    }

    .border-lace {
        width: 90vw;
        padding: 18px;
    }

    .extra-panel {
        width: 90vw;
        padding: 18px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .ticker-track {
        animation: none;
    }
}