/* =====================================================
   Hellmann's – Bring Out The Best  |  Form UI
   ===================================================== */

@font-face {
    font-family: 'DollopSans';
    src: url('fonts/DollopSans-Condensed.otf') format('opentype');
    font-weight: 700;
    font-style: normal;
}

@font-face {
    font-family: 'DollopSansExpanded';
    src: url('fonts/DollopSans-Expanded.otf') format('opentype');
    font-weight: 400;
    font-style: normal;
}

@font-face {
    font-family: 'ArialBold';
    src: url('fonts/arialbd.ttf') format('truetype');
    font-weight: 700;
    font-style: normal;
}

@font-face {
    font-family: 'ArialNarrow';
    src: url('fonts/ARIALNB.TTF') format('truetype');
    font-weight: 700;
    font-style: normal;
}

/* ── Reset & Base ── */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html,
body {
    height: 100%;
    width: 100%;
}

body {
    font-family: 'ArialBold', Arial, sans-serif;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #0a4a6e;
}

/* ── Page Wrapper ── */
.page-wrapper {
    position: relative;
    width: 100%;
    max-width: 430px;
    min-height: 100vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* ── Background ── */
.bg-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 108%;
    object-fit: cover;
    object-position: center top;
    z-index: 0;
}

/* ── Content Layer ── */
.content {
    position: relative;
    z-index: 1;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0 28px 80px;
}

/* ── Logo ── */
.logo-wrap {
    margin-top: 36px;
    margin-bottom: 20px;
}

.logo-wrap img {
    width: 160px;
    height: auto;
    display: block;
}

/* ── Heading Block ── */
.heading-block {
    text-align: center;
    margin-bottom: 28px;
}

.tagline {
    font-family: 'DollopSans', serif;
    font-size: 22px;
    color: #f2e3ce;
    letter-spacing: 0.02em;
    margin-bottom: 4px;
}

.hero-title {
    font-family: 'DollopSansExpanded', 'ArialBold', sans-serif;
    font-size: 40px;
    line-height: 0.95;
    color: #f2e3ce;
    text-transform: lowercase;
    letter-spacing: 0.05em;
    margin-bottom: 16px;
    line-height: 1.2;
}

/* ── Bowtie Decoration ── */
.bowtie-img {
    display: block;
    width: 130px;
    height: auto;
    margin: 0 auto;
}

/* ── Form ── */
.form-section {
    width: 100%;
    display: flex;
    flex-direction: column;
    margin-top: 2px;
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 7px;
}

.form-group label {
    font-family: 'ArialNarrow', 'ArialBold', Arial, sans-serif;
    font-size: 18px;
    font-weight: 700;
    color: #f2e3ce;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    text-align: center;
}

.form-group input {
    width: 100%;
    height: 54px;
    background-color: #f2e3ce;
    border: none;
    border-radius: 8px;
    padding: 0 18px;
    font-size: 16px;
    font-family: 'ArialBold', Arial, sans-serif;
    color: #1a3a5c;
    outline: none;
    transition: box-shadow 0.2s ease;
}

.form-group input::placeholder {
    color: #c8b89a;
}

.form-group input:focus {
    box-shadow: 0 0 0 3px rgba(245, 230, 200, 0.5);
}

/* ── Toast Notification ── */
.toast {
    position: fixed;
    top: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(-16px);
    background-color: #f2e3ce;
    color: #155070;
    font-family: 'ArialBold', Arial, sans-serif;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.04em;
    padding: 14px 24px;
    border-radius: 10px;
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.35);
    z-index: 9999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease, transform 0.25s ease;
    white-space: nowrap;
    max-width: 90vw;
    text-align: center;
}

.toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
    pointer-events: auto;
}

/* ── NEXT Button ── */
.btn-next {
    display: block;
    margin: 32px auto 0;
    width: 128px;
    height: 52px;
    background-color: #f2e3ce;
    border: none;
    border-radius: 12px;
    font-family: 'ArialBold', Arial, sans-serif;
    font-size: 25px;
    font-weight: 700;
    color: #155070;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    cursor: pointer;
    box-shadow: 0 4px 1px rgb(20 79 111);
    transition: background-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease, transform 0.15s ease;
}

.btn-next:hover {
    background-color: #ede0cc;
    box-shadow: 0 5px 14px rgba(0, 0, 0, 0.35);
    transform: scale(1.03);
}

.btn-next:active {
    transform: scale(0.97);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

/* ── Button spinner ── */
@keyframes btn-spin {
    to { transform: rotate(360deg); }
}

.btn-spinner {
    display: inline-block;
    width: 22px;
    height: 22px;
    border: 3px solid rgba(21, 80, 112, 0.3);
    border-top-color: #155070;
    border-radius: 50%;
    animation: btn-spin 0.7s linear infinite;
    vertical-align: middle;
}

/* ── Bottom Products ── */
.products-section {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 240px;
    z-index: 2;
    pointer-events: none;
}

.products-section img {
    position: absolute;
    bottom: 0;
}

.img-plate {
    left: -25px;
    width: 256px;
    height: auto;
}

.img-garlic {
    right: 67px;
    bottom: 17px !important;
    width: 126px;
    height: auto;
}

.img-chilli {
    right: 18px;
    bottom: 4px !important;
    width: 144px;
    height: auto;
}

.img-light {
    right: -5px;
    bottom: -4px !important;
    width: 134px;
    height: auto;
}

.img-jar {
    right: -97px;
    bottom: -18px !important;
    width: 190px;
    height: auto;
}

/* ── Success Screen (hidden by default) ── */
.success-screen {
    display: none;
    position: relative;
    z-index: 1;
    width: 100%;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 28px;
    text-align: center;
    min-height: 60vh;
}

.success-screen.visible {
    display: flex;
}

.success-icon {
    font-size: 60px;
    margin-bottom: 20px;
}

.success-title {
    font-family: 'DollopSans', 'ArialBold', sans-serif;
    font-size: 48px;
    color: #f2e3ce;
    text-transform: lowercase;
    line-height: 1;
    margin-bottom: 12px;
}

.success-msg {
    font-family: 'DollopSansExpanded', serif;
    font-size: 18px;
    color: #f2e3ce;
    letter-spacing: 0.03em;
}

/* =====================================================
   Page-load entrance animations
   ===================================================== */

@keyframes fadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(32px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-28px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes popIn {
    from {
        opacity: 0;
        transform: scale(0.6);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* fill-mode: both keeps elements invisible before their delay fires */

.bg-image {
    animation: fadeIn 1s ease both;
    animation-delay: 0s;
}

.logo-wrap {
    animation: slideDown 0.6s cubic-bezier(0.22, 1, 0.36, 1) both;
    animation-delay: 0.2s;
}

.tagline {
    animation: slideUp 0.5s cubic-bezier(0.22, 1, 0.36, 1) both;
    animation-delay: 0.45s;
}

.hero-title {
    animation: slideUp 0.55s cubic-bezier(0.22, 1, 0.36, 1) both;
    animation-delay: 0.6s;
}

.bowtie-img {
    animation: popIn 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) both;
    animation-delay: 0.8s;
}

/* Form groups – staggered */
.form-section .form-group:nth-child(1) {
    animation: slideUp 0.5s cubic-bezier(0.22, 1, 0.36, 1) both;
    animation-delay: 0.95s;
}

.form-section .form-group:nth-child(2) {
    animation: slideUp 0.5s cubic-bezier(0.22, 1, 0.36, 1) both;
    animation-delay: 1.1s;
}

.form-section .form-group:nth-child(3) {
    animation: slideUp 0.5s cubic-bezier(0.22, 1, 0.36, 1) both;
    animation-delay: 1.25s;
}

.btn-next {
    animation: slideUp 0.5s cubic-bezier(0.22, 1, 0.36, 1) both;
    animation-delay: 1.4s;
}

/* Product images – slide up from bottom edge */
.img-plate {
    animation: slideUp 0.7s cubic-bezier(0.22, 1, 0.36, 1) both;
    animation-delay: 0.3s;
}

.img-garlic {
    animation: slideUp 0.7s cubic-bezier(0.22, 1, 0.36, 1) both;
    animation-delay: 0.5s;
}

.img-chilli {
    animation: slideUp 0.7s cubic-bezier(0.22, 1, 0.36, 1) both;
    animation-delay: 0.6s;
}

.img-light {
    animation: slideUp 0.7s cubic-bezier(0.22, 1, 0.36, 1) both;
    animation-delay: 0.7s;
}

.img-jar {
    animation: slideUp 0.7s cubic-bezier(0.22, 1, 0.36, 1) both;
    animation-delay: 0.8s;
}