/* ===== Design tokens ===== */
:root {
    --purple-deep: #2d0a4e;
    --purple-mid: #5b2d8a;
    --purple-light: #9b6fc7;
    --lavender: #e8d5f5;
    --gold: #d4a853;
    --gold-light: #a67c2a;
    --gold-dark: #8a6520;
    --white: #ffffff;
    --paper: #f5f0eb;
    --text: #2d0a4e;
    --text-muted: rgba(45, 10, 78, 0.72);
    --nav-height: 64px;
    --safe-bottom: env(safe-area-inset-bottom, 0px);
    --font-script: 'Great Vibes', cursive;
    --font-serif: 'Cormorant Garamond', Georgia, serif;
    --font-sans: 'Montserrat', system-ui, sans-serif;
    --radius: 14px;
    --shadow: 0 4px 24px rgba(45, 10, 78, 0.12);
    --content-max: 480px;
    --content-pad-x: 1rem;
    --content-pad-top: 1.25rem;
}

/* ===== Reset ===== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
    scrollbar-gutter: stable;
}

body {
    font-family: var(--font-sans);
    background-color: var(--paper);
    color: var(--text);
    min-height: 100dvh;
    line-height: 1.5;
    overflow-x: hidden;
}

.paper-texture {
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background-color: var(--paper);
    background-image: url('../images/papel%20textura%202.png');
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
}

img {
    display: block;
    max-width: 100%;
    height: auto;
}

a {
    color: inherit;
    text-decoration: none;
}

/* ===== Layout ===== */
.main-content {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: var(--content-max);
    margin-left: auto;
    margin-right: auto;
    min-height: calc(100dvh - var(--nav-height) - var(--safe-bottom));
    padding: var(--content-pad-top) var(--content-pad-x) calc(var(--nav-height) + var(--safe-bottom) + 12px);
}

/* ===== Flores decorativas (todas as páginas) ===== */
.flores-decor {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
}

.flores-decor__item {
    position: absolute;
    width: clamp(130px, 28vw, 200px);
    height: auto;
    opacity: 0.92;
    mix-blend-mode: screen;
    filter: drop-shadow(0 4px 12px rgba(91, 45, 138, 0.12));
    z-index: 0;
}

.flores-decor__item--overlap {
    z-index: 2;
}

/* Mobile: parcial nas bordas, algumas sobre o conteúdo */
.flores-decor__item--1 {
    top: 2%;
    left: -22%;
    transform: rotate(-16deg);
}

.flores-decor__item--2 {
    top: 28%;
    right: -26%;
    transform: rotate(24deg) scale(0.92);
}

.flores-decor__item--3 {
    top: 52%;
    left: -18%;
    transform: rotate(7deg) scale(0.88);
}

.flores-decor__item--4 {
    bottom: 8%;
    right: -24%;
    transform: rotate(-19deg) scale(1.05);
}

.flores-decor__item--5,
.flores-decor__item--6 {
    display: none;
}

.flores-decor__item--2,
.flores-decor__item--3,
.flores-decor__item--4 {
    z-index: 2;
}

@media (min-width: 768px) {
    .flores-decor__item {
        width: clamp(155px, 13vw, 230px);
    }

    .flores-decor__item--1 {
        top: 5%;
        left: calc(50% - var(--content-max) / 2 - 8%);
        transform: rotate(-13deg);
        z-index: 0;
    }

    .flores-decor__item--2 {
        top: 14%;
        right: calc(50% - var(--content-max) / 2 - 6%);
        transform: rotate(31deg) scale(0.9);
        z-index: 2;
    }

    .flores-decor__item--3 {
        top: 47%;
        left: calc(50% - var(--content-max) / 2 - 10%);
        transform: rotate(4deg) scale(0.95);
        z-index: 2;
    }

    .flores-decor__item--4 {
        top: 61%;
        right: calc(50% - var(--content-max) / 2 - 4%);
        transform: rotate(-27deg) scale(1.02);
        z-index: 0;
    }

    .flores-decor__item--5 {
        display: block;
        bottom: 26%;
        left: calc(50% - var(--content-max) / 2 - 2%);
        transform: rotate(19deg) scale(0.78);
        z-index: 2;
    }

    .flores-decor__item--6 {
        display: block;
        bottom: 10%;
        right: calc(50% - var(--content-max) / 2 - 9%);
        transform: rotate(-9deg) scale(0.86);
        z-index: 2;
    }
}

@media (min-width: 1200px) {
    .flores-decor__item--1 { left: calc(50% - var(--content-max) / 2 - 12%); }
    .flores-decor__item--2 { right: calc(50% - var(--content-max) / 2 - 3%); }
    .flores-decor__item--5 { left: calc(50% - var(--content-max) / 2 + 1%); }
}

/* ===== Bottom navigation ===== */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    z-index: 100;
    display: flex;
    width: 100%;
    max-width: var(--content-max);
    height: calc(var(--nav-height) + var(--safe-bottom));
    padding-bottom: var(--safe-bottom);
    background: rgba(255, 255, 255, 0.88);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-top: 1px solid rgba(91, 45, 138, 0.2);
    box-shadow: 0 -4px 20px rgba(45, 10, 78, 0.08);
}

.bottom-nav__link {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    padding: 8px 4px;
    color: var(--text-muted);
    transition: color 0.2s, background 0.2s;
    -webkit-tap-highlight-color: transparent;
}

.bottom-nav__link.is-active {
    color: var(--purple-mid);
    background: rgba(91, 45, 138, 0.08);
}

.bottom-nav__link.is-active .bottom-nav__icon svg {
    stroke-width: 2.1;
}

.bottom-nav__link:active {
    background: rgba(91, 45, 138, 0.14);
}

.bottom-nav__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 1.5rem;
    height: 1.5rem;
    color: #a67c2a;
    line-height: 1;
}

.bottom-nav__icon svg {
    width: 100%;
    height: 100%;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.75;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.bottom-nav__label {
    font-size: 0.65rem;
    font-weight: 500;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

/* ===== Convite page ===== */
.page-convite .main-content {
    min-height: 100dvh;
    padding-bottom: calc(var(--safe-bottom) + 1rem);
}

.page-convite {
    --convite-text: #4b2c20;
    --font-convite: 'Sacramento', cursive;
}

.page-convite .flores-decor {
    display: none;
}

.convite-page {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: calc(100dvh - var(--content-pad-top) - var(--safe-bottom) - 1rem);
    font-family: var(--font-convite);
    color: var(--convite-text);
    text-align: center;
}

.convite-page__body {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    gap: 0;
}

/* Mesmo princípio da página Informações: fixo na tela, parcial nas bordas */
.convite-page__flores-wrap {
    position: fixed;
    inset: 0;
    z-index: 2;
    pointer-events: none;
    overflow: hidden;
}

.convite-page__flores {
    position: absolute;
    width: clamp(150px, 42vw, 200px);
    height: auto;
    pointer-events: none;
    mix-blend-mode: multiply;
    opacity: 0.88;
}

.convite-page__flores--top-left {
    top: 2%;
    left: -10%;
    transform: rotate(-8deg);
}

.convite-page__flores--bottom-right {
    bottom: 6%;
    right: -12%;
    transform: rotate(172deg);
}

.convite-page__flores--env-left {
    top: 38%;
    left: -8%;
    transform: rotate(-12deg) scale(0.94);
}

.convite-page__flores--env-right {
    top: 40%;
    right: -10%;
    transform: rotate(10deg) scaleX(-1) scale(0.94);
}

@media (min-width: 768px) {
    .convite-page__flores {
        width: clamp(155px, 13vw, 230px);
    }

    .convite-page__flores--top-left {
        top: calc(5% - 80px);
        left: calc(50% - var(--content-max) / 2 - 8%);
        transform: rotate(-6deg);
    }

    .convite-page__flores--env-left {
        top: 47%;
        left: calc(50% - var(--content-max) / 2 - 10%);
        transform: rotate(-8deg) scale(0.95);
    }

    .convite-page__flores--env-right {
        top: calc(48% - 280px);
        right: calc(50% - var(--content-max) / 2 - 6%);
        left: auto;
        transform: rotate(8deg) scaleX(-1) scale(0.95);
    }

    .convite-page__flores--bottom-right {
        bottom: 10%;
        right: calc(50% - var(--content-max) / 2 - 9%);
        transform: rotate(180deg);
    }
}

@media (min-width: 1200px) {
    .convite-page__flores--top-left {
        left: calc(50% - var(--content-max) / 2 - 12%);
    }

    .convite-page__flores--env-left {
        left: calc(50% - var(--content-max) / 2 - 12%);
    }

    .convite-page__flores--env-right {
        right: calc(50% - var(--content-max) / 2 - 3%);
    }

    .convite-page__flores--bottom-right {
        right: calc(50% - var(--content-max) / 2 - 6%);
    }
}

.convite-page__name {
    font-family: var(--font-convite);
    font-size: clamp(2.4rem, 9vw, 3.2rem);
    font-weight: 400;
    line-height: 0.95;
    margin: 0 0 clamp(-2.2rem, -8.5vw, -3rem);
}

.convite-page__envelope {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-width: 340px;
    padding: 0;
    margin: 0;
}

.convite-page__envelope-wrap {
    position: relative;
    width: 100%;
    max-width: 300px;
}

.convite-page__image {
    width: 100%;
    height: auto;
    object-fit: contain;
    filter: drop-shadow(0 6px 20px rgba(75, 44, 32, 0.12));
}

@keyframes convite-seal-pulse {
    0%,
    82%,
    100% {
        transform: translate(-50%, -50%) scale(1);
        filter: brightness(1);
    }
    88% {
        transform: translate(-50%, -50%) scale(1.12);
        filter: brightness(1.1);
    }
    94% {
        transform: translate(-50%, -50%) scale(1);
        filter: brightness(1);
    }
}

.convite-page__seal {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: clamp(72px, 24vw, 105px);
    z-index: 2;
    transition: filter 0.2s ease;
    animation: convite-seal-pulse 4s ease-in-out infinite;
    -webkit-tap-highlight-color: transparent;
    cursor: pointer;
    text-decoration: none;
}

.convite-page__seal:hover {
    filter: brightness(1.05);
}

.convite-page__seal:active {
    animation: none;
    transform: translate(-50%, -50%) scale(0.94);
}

@media (prefers-reduced-motion: reduce) {
    .convite-page__seal {
        animation: none;
    }
}

.convite-page__seal-img {
    width: 100%;
    height: auto;
    display: block;
    pointer-events: none;
}

.convite-page__seal-arc {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 148%;
    transform: translate(-50%, -44%);
    overflow: visible;
    pointer-events: none;
}

.convite-page__seal-text {
    font-family: var(--font-convite);
    font-size: clamp(24px, 7.2vw, 32px);
    fill: var(--convite-text);
    letter-spacing: 0.05em;
}

.convite-page__tagline {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: clamp(-2.8rem, -11.5vw, -4rem);
    gap: 0;
}

.convite-page__subtitle {
    font-family: var(--font-convite);
    font-size: clamp(2rem, 7.5vw, 2.75rem);
    font-weight: 400;
    line-height: 1;
    margin: 0;
}

.convite-page__highlight {
    font-family: var(--font-convite);
    font-size: clamp(3rem, 12vw, 4.25rem);
    font-weight: 400;
    line-height: 1;
    margin: -0.05rem 0 0;
    letter-spacing: 0.02em;
    color: var(--convite-text);
    text-shadow: 0 2px 14px rgba(75, 44, 32, 0.12);
}

/* ===== Lista page ===== */
.page-lista {
    --lista-text: #4b2c20;
    --font-lista: 'Sacramento', cursive;
}

.lista-page {
    width: 100%;
}

.lista-page__title {
    font-family: var(--font-lista);
    font-size: clamp(2rem, 8vw, 2.8rem);
    font-weight: 400;
    color: var(--lista-text);
    text-align: center;
    margin-bottom: 1.75rem;
    line-height: 1.2;
}

.lista-page__items {
    list-style: none;
    border: 2px solid var(--gold);
    border-radius: var(--radius);
    padding: 1.25rem 1.5rem;
    background: rgba(255, 255, 255, 0.55);
    box-shadow: var(--shadow);
}

.lista-page__item {
    font-family: var(--font-serif);
    font-size: clamp(1rem, 3.5vw, 1.1rem);
    color: var(--purple-deep);
    padding: 0.6rem 0;
    padding-left: 1.25rem;
    position: relative;
    line-height: 1.45;
    border-bottom: 1px solid rgba(212, 168, 83, 0.2);
}

.lista-page__item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.lista-page__item::before {
    content: '•';
    position: absolute;
    left: 0;
    color: var(--gold);
    font-size: 1.1rem;
    line-height: 1.45;
}

.lista-page__empty {
    text-align: center;
    color: var(--text-muted);
    font-size: 0.95rem;
}

.lista-page__actions {
    margin-top: 1.5rem;
}

.lista-page__notice {
    margin-top: 0.85rem;
    font-family: var(--font-serif);
    font-size: 0.78rem;
    font-style: italic;
    line-height: 1.55;
    text-align: center;
    color: var(--text-muted);
    padding: 0 0.25rem;
}

.lista-page__notice-link {
    color: var(--purple-mid);
    text-decoration: underline;
    text-underline-offset: 2px;
    font-style: normal;
    font-weight: 600;
}

.lista-page__notice-link:hover {
    color: var(--purple-deep);
}

/* ===== Blank pages ===== */
.page-blank {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: calc(100dvh - var(--nav-height) - var(--safe-bottom) - var(--content-pad-top) - 12px);
}

.page-blank__inner {
    width: 100%;
    min-height: 60dvh;
    border: 2px dashed rgba(91, 45, 138, 0.25);
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.35);
}

.page-blank__text {
    text-align: center;
    color: var(--text-muted);
    font-size: 0.95rem;
    padding: 2rem;
}

/* ===== Informações page ===== */
.info-page {
    width: 100%;
}

.info-page__content {
    width: 100%;
}

.info-hero {
    position: relative;
    width: 100%;
    margin-bottom: 1.25rem;
}

.info-hero__frame {
    position: relative;
    width: 100%;
    aspect-ratio: 3 / 4;
    max-height: 70dvh;
    overflow: hidden;
    border-radius: var(--radius);
    background: var(--purple-deep);
}

.info-hero__photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
}

.info-hero__sparkles {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 1;
    overflow: hidden;
}

.info-hero__sparkle {
    position: absolute;
    width: clamp(110px, 38vw, 170px);
    height: auto;
    object-fit: contain;
    mix-blend-mode: screen;
    opacity: 0.88;
}

.info-hero__sparkle--bl {
    bottom: -4%;
    left: -6%;
    transform: rotate(168deg) scale(0.95);
    transform-origin: bottom left;
}

.info-hero__sparkle--br {
    bottom: -4%;
    right: -6%;
    left: auto;
    transform: rotate(-12deg) scaleX(-1) scale(0.95);
    transform-origin: bottom right;
}

.info-hero__overlay {
    position: absolute;
    top: clamp(7%, 9vw, 11%);
    left: clamp(5%, 6vw, 9%);
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.1rem;
    max-width: 58%;
    padding: 0;
    text-align: center;
    pointer-events: none;
}

.info-hero__crown-img {
    width: clamp(38px, 12vw, 54px);
    height: auto;
    display: block;
    margin: 0;
    filter: drop-shadow(0 2px 8px rgba(45, 10, 78, 0.35));
}

.info-hero__title {
    font-family: var(--font-script);
    font-size: clamp(1.75rem, 7.5vw, 2.5rem);
    color: var(--gold-light);
    line-height: 1;
    margin: 0;
    width: 100%;
    text-align: center;
    text-shadow:
        0 1px 3px rgba(255, 255, 255, 0.55),
        0 2px 10px rgba(45, 10, 78, 0.45);
}

.info-hero__name {
    font-family: var(--font-script);
    font-size: clamp(1.25rem, 5.2vw, 1.7rem);
    color: var(--lavender);
    margin: 0;
    width: 100%;
    text-align: center;
    line-height: 1.15;
    text-shadow:
        0 1px 3px rgba(255, 255, 255, 0.5),
        0 2px 10px rgba(45, 10, 78, 0.4);
}

.info-message {
    font-family: var(--font-serif);
    font-size: 1.05rem;
    font-style: italic;
    text-align: center;
    color: var(--purple-mid);
    margin-bottom: 1.25rem;
    line-height: 1.65;
}

.info-card {
    border: 2px solid var(--gold);
    border-radius: var(--radius);
    padding: 1.1rem 1.25rem;
    background: rgba(255, 255, 255, 0.55);
    box-shadow: var(--shadow);
    margin-bottom: 1.25rem;
}

.info-card__row {
    padding: 0.65rem 0;
    border-bottom: 1px solid rgba(212, 168, 83, 0.2);
}

.info-card__row:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.info-card__row:first-child {
    padding-top: 0;
}

.info-card__label {
    display: block;
    font-family: var(--font-serif);
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 0.15rem;
}

.info-card__value {
    font-family: var(--font-serif);
    font-size: 1rem;
    color: var(--purple-deep);
    line-height: 1.5;
}

.info-actions {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

.info-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.9rem 1.25rem;
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 500;
    text-align: center;
    transition: transform 0.15s, box-shadow 0.15s;
    -webkit-tap-highlight-color: transparent;
}

.info-btn:active {
    transform: scale(0.98);
}

.info-btn--map {
    background: rgba(255, 255, 255, 0.7);
    border: 2px solid var(--gold);
    color: var(--purple-deep);
}

.info-btn--whatsapp {
    background: linear-gradient(135deg, #25d366, #128c7e);
    color: var(--white);
    box-shadow: 0 4px 16px rgba(37, 211, 102, 0.35);
}

.info-btn--gifts {
    background: linear-gradient(135deg, var(--purple-mid), var(--purple-deep));
    color: var(--white);
    box-shadow: 0 4px 16px rgba(91, 45, 138, 0.3);
}

.info-footer-msg {
    font-size: 0.9rem;
    text-align: center;
    color: var(--text-muted);
    padding: 0.5rem 0.5rem 1rem;
    line-height: 1.6;
}

/* ===== Tablet / Desktop ===== */
@media (min-width: 600px) {
    :root {
        --content-max: 520px;
    }

    .bottom-nav {
        border-radius: var(--radius) var(--radius) 0 0;
        border-left: 1px solid rgba(91, 45, 138, 0.2);
        border-right: 1px solid rgba(91, 45, 138, 0.2);
    }
}
