/* ================================================================
   KENYA GAMES — Playful Candy Design System
   Shared stylesheet for: index.html, subscription.html, success.html
   Font: Fredoka One (display) + Nunito (body)
   ================================================================ */

@import url('https://fonts.googleapis.com/css2?family=Fredoka+One&family=Nunito:wght@400;600;700;800;900&display=swap');

* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
    --pink:       #ff6b9d;
    --pink-lt:    #ffa8c8;
    --pink-pale:  #fff0f6;
    --purple:     #c77dff;
    --purple-dk:  #9b4dca;
    --mint:       #4ecdc4;
    --yellow:     #ffd93d;
    --coral:      #ff9f43;
    --sky:        #74b9ff;
    --green:      #55efc4;
    --rose:       #ff7675;
    --bg:         #fff8fb;
    --white:      #ffffff;
    --text:       #2d2d2d;
    --text-2:     #777777;
    --text-3:     #bbbbbb;
    --border-candy: rgba(255,107,157,0.15);
}

/* ── base ── */
body {
    font-family: 'Nunito', sans-serif;
    background: var(--bg);
    min-height: 100vh;
    color: var(--text);
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding: 0 16px 52px;
    overflow-x: hidden;
}

/* polka-dot texture */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    background-image: radial-gradient(circle, #ffd6e8 1.8px, transparent 1.8px);
    background-size: 28px 28px;
    opacity: 0.45;
    pointer-events: none;
    z-index: 0;
}

/* ── container ── */
.container {
    max-width: 480px;
    width: 100%;
    position: relative;
    z-index: 1;
}

/* ── header ── */
.header {
    text-align: center;
    padding: 40px 0 28px;
}

.logo {
    font-family: 'Fredoka One', cursive;
    font-size: 36px;
    background: linear-gradient(135deg, #ff6b9d, #c77dff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: 0.5px;
    line-height: 1;
    filter: drop-shadow(0 2px 8px rgba(255,107,157,0.25));
}

/* hide the old star span */
.logo .star { display: none; }

.tagline {
    color: var(--text-3);
    font-size: 13px;
    font-weight: 700;
    margin-top: 8px;
}

/* ── main card ── */
.subscription-card {
    background: var(--white);
    border: 2px solid #ffd6e8;
    border-radius: 28px;
    padding: 32px 24px 28px;
    box-shadow: 0 8px 32px rgba(255,107,157,0.12), 0 2px 8px rgba(0,0,0,0.04);
}

.subscription-card h1 {
    font-family: 'Fredoka One', cursive;
    font-size: 26px;
    font-weight: 400; /* Fredoka One is always bold */
    color: var(--text);
    margin-bottom: 10px;
    text-align: center;
    letter-spacing: 0.3px;
    line-height: 1.2;
}

.description {
    color: var(--text-2);
    font-size: 14px;
    font-weight: 600;
    line-height: 1.7;
    text-align: center;
    margin-bottom: 24px;
}

/* ── features 2×2 grid ── */
.features {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-bottom: 24px;
}

.feature-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 18px 10px;
    border-radius: 20px;
    text-align: center;
    border: 2px solid transparent;
    transition: transform 0.2s cubic-bezier(.34,1.56,.64,1), box-shadow 0.2s;
}

/* pastel gradient per feature tile */
.feature-item:nth-child(1) { background: linear-gradient(145deg, #ffe0ec, #ffc8dc); border-color: #ffadd0; }
.feature-item:nth-child(2) { background: linear-gradient(145deg, #f0e6ff, #e4d0ff); border-color: #d4b0ff; }
.feature-item:nth-child(3) { background: linear-gradient(145deg, #fffbe0, #fff3a8); border-color: #ffe980; }
.feature-item:nth-child(4) { background: linear-gradient(145deg, #ddfdf9, #c4f5f0); border-color: #a0eae4; }

.feature-item:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 6px 18px rgba(255,107,157,0.15);
}

.feature-item .icon {
    font-size: 32px;
    line-height: 1;
}

.feature-item p {
    font-size: 12px;
    font-weight: 800;
    color: #3a2a4a;
}

/* ── pricing block ── */
.pricing {
    text-align: center;
    margin-bottom: 20px;
    padding: 24px 20px;
    background: linear-gradient(135deg, #ff6b9d 0%, #c77dff 60%, #74b9ff 100%);
    border-radius: 22px;
    color: white;
    position: relative;
    overflow: hidden;
    box-shadow: 0 6px 24px rgba(255,107,157,0.35);
}
.pricing::before {
    content: '';
    position: absolute;
    top: -30px; right: -30px;
    width: 120px; height: 120px;
    background: rgba(255,255,255,0.12);
    border-radius: 50%;
    pointer-events: none;
}
.pricing::after {
    content: '';
    position: absolute;
    bottom: -20px; left: -20px;
    width: 80px; height: 80px;
    background: rgba(255,255,255,0.08);
    border-radius: 50%;
    pointer-events: none;
}

.pricing h3 {
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: rgba(255,255,255,0.85);
    margin-bottom: 8px;
    position: relative;
    z-index: 1;
}

.price {
    font-family: 'Fredoka One', cursive;
    font-size: 52px;
    color: #fff;
    line-height: 1;
    margin: 8px 0;
    text-shadow: 0 2px 10px rgba(0,0,0,0.12);
    position: relative;
    z-index: 1;
}

.price span {
    font-family: 'Nunito', sans-serif;
    font-size: 20px;
    font-weight: 700;
    color: rgba(255,255,255,0.8);
}

.note {
    font-size: 12px;
    color: rgba(255,255,255,0.8);
    font-weight: 700;
    position: relative;
    z-index: 1;
}

/* ── important notice ── */
.important-notice {
    background: #fffbe0;
    border-left: 4px solid var(--yellow);
    padding: 12px 14px;
    margin: 18px 0;
    border-radius: 0 14px 14px 0;
}
.important-notice p {
    margin: 0;
    color: #856404;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.5;
}

/* ── subscribe button ── */
.subscribe-btn {
    width: 100%;
    background: linear-gradient(135deg, #ff6b9d, #c77dff);
    color: #fff;
    border: none;
    padding: 17px;
    border-radius: 100px;
    font-family: 'Nunito', sans-serif;
    font-size: 16px;
    font-weight: 900;
    letter-spacing: 0.5px;
    cursor: pointer;
    box-shadow: 0 6px 20px rgba(255,107,157,0.4), 0 2px 0 rgba(0,0,0,0.06);
    transition: transform 0.2s cubic-bezier(.34,1.56,.64,1), box-shadow 0.2s;
}
.subscribe-btn:hover {
    transform: translateY(-3px) scale(1.01);
    box-shadow: 0 12px 28px rgba(255,107,157,0.5);
}
.subscribe-btn:active {
    transform: translateY(1px) scale(0.99);
    box-shadow: 0 3px 10px rgba(255,107,157,0.3);
}

/* ── loading state ── */
.loading-state,
.error-state,
.processing-state,
.success-state {
    text-align: center;
    padding: 24px 16px;
}

.spinner {
    width: 48px; height: 48px;
    border: 3px solid #ffd6e8;
    border-top-color: var(--pink);
    border-radius: 50%;
    animation: spin 0.75s linear infinite;
    margin: 0 auto 18px;
}

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

.loading-state p {
    font-size: 14px;
    font-weight: 800;
    color: #3a2a4a;
    margin-bottom: 4px;
}
.loading-state .note {
    font-size: 12px;
    color: var(--text-3);
    font-weight: 600;
}

/* ── error state ── */
.error-state .error-icon {
    font-size: 56px;
    display: block;
    margin-bottom: 14px;
}
.error-state p {
    font-size: 14px;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 16px;
}

/* ── buttons ── */
.retry-btn {
    display: inline-block;
    background: linear-gradient(135deg, #ffd93d, #ff9f43);
    color: #fff;
    border: none;
    padding: 11px 28px;
    border-radius: 100px;
    font-family: 'Nunito', sans-serif;
    font-size: 13px;
    font-weight: 900;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(255,159,67,0.4);
    transition: transform 0.2s, box-shadow 0.2s;
}
.retry-btn:hover { transform: translateY(-2px); box-shadow: 0 7px 20px rgba(255,159,67,0.5); }

.continue-btn,
.dashboard-btn {
    display: inline-block;
    background: linear-gradient(135deg, #ff6b9d, #c77dff);
    color: #fff;
    border: none;
    padding: 14px 36px;
    border-radius: 100px;
    font-family: 'Nunito', sans-serif;
    font-size: 15px;
    font-weight: 900;
    cursor: pointer;
    margin-top: 20px;
    box-shadow: 0 6px 20px rgba(255,107,157,0.35);
    transition: transform 0.2s cubic-bezier(.34,1.56,.64,1), box-shadow 0.2s;
    text-decoration: none;
}
.continue-btn:hover,
.dashboard-btn:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 10px 28px rgba(255,107,157,0.45);
}

.primary-btn {
    display: inline-block;
    background: linear-gradient(135deg, #4ecdc4, #74b9ff);
    color: #fff;
    border: none;
    padding: 14px 36px;
    border-radius: 100px;
    font-family: 'Nunito', sans-serif;
    font-size: 15px;
    font-weight: 900;
    cursor: pointer;
    text-decoration: none;
    box-shadow: 0 6px 18px rgba(78,205,196,0.35);
    transition: transform 0.2s, box-shadow 0.2s;
}
.primary-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(78,205,196,0.45);
}

.danger-btn {
    display: inline-block;
    background: linear-gradient(135deg, #ff7675, #ff6b9d);
    color: #fff;
    border: none;
    padding: 14px 36px;
    border-radius: 100px;
    font-family: 'Nunito', sans-serif;
    font-size: 15px;
    font-weight: 900;
    cursor: pointer;
    box-shadow: 0 6px 18px rgba(255,118,117,0.35);
    transition: transform 0.2s, box-shadow 0.2s;
}
.danger-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(255,118,117,0.45);
}
.danger-btn:active { transform: translateY(0); }

.secondary-btn {
    display: inline-block;
    background: #f5f5f5;
    border: 2px solid #e0e0e0;
    color: #777;
    padding: 14px 36px;
    border-radius: 100px;
    font-family: 'Nunito', sans-serif;
    font-size: 15px;
    font-weight: 800;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.2s;
}
.secondary-btn:hover { background: #ebebeb; }

.action-buttons {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin-top: 24px;
    flex-wrap: wrap;
}

/* ── progress steps ── */
.progress-steps {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin: 28px 0;
}

.step {
    text-align: center;
    opacity: 0.3;
    transition: opacity 0.3s;
}
.step.active { opacity: 1; }
.step p {
    font-size: 11px;
    font-weight: 800;
    color: var(--text-2);
    margin-top: 6px;
}

.step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px; height: 40px;
    border-radius: 50%;
    background: #f0f0f0;
    color: #aaa;
    font-weight: 900;
    font-size: 14px;
    border: 2px solid #e0e0e0;
}

.step.active .step-number {
    background: linear-gradient(135deg, #ff6b9d, #c77dff);
    border-color: transparent;
    color: #fff;
    box-shadow: 0 4px 14px rgba(255,107,157,0.45);
    animation: pulse-step 1.2s ease-in-out infinite;
}

@keyframes pulse-step {
    0%, 100% { box-shadow: 0 4px 14px rgba(255,107,157,0.45); }
    50%       { box-shadow: 0 4px 24px rgba(255,107,157,0.75); transform: scale(1.08); }
}

.phone-number {
    font-size: 16px;
    font-weight: 800;
    color: var(--pink);
    margin: 14px 0;
    letter-spacing: 1px;
}

/* ── success animation ── */
.success-icon {
    font-size: 76px;
    display: block;
    margin-bottom: 16px;
}

.success-animation { margin-bottom: 24px; }

.checkmark-circle {
    width: 96px; height: 96px;
    border-radius: 50%;
    background: linear-gradient(135deg, #55efc4, #4ecdc4);
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 28px rgba(78,205,196,0.45);
    animation: scaleIn 0.5s cubic-bezier(.34,1.56,.64,1) forwards;
}

@keyframes scaleIn {
    0%   { transform: scale(0); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}

.checkmark {
    width: 22px; height: 46px;
    border: solid #fff;
    border-width: 0 5px 5px 0;
    transform: rotate(45deg) translateY(-4px);
    animation: drawCheck 0.4s ease 0.4s backwards;
}
@keyframes drawCheck {
    0%   { height: 0; }
    100% { height: 46px; }
}

.welcome-text {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-2);
    margin-bottom: 24px;
    line-height: 1.6;
    text-align: center;
}

/* ── next steps ── */
.next-steps { margin: 24px 0; }

.next-steps h3 {
    font-family: 'Fredoka One', cursive;
    font-size: 20px;
    color: var(--pink);
    margin-bottom: 14px;
    text-align: center;
}

.step-list { display: flex; flex-direction: column; gap: 10px; }

.step-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
    background: var(--pink-pale);
    border: 1.5px solid #ffd6e8;
    border-radius: 16px;
    transition: transform 0.2s;
}
.step-item:hover { transform: translateX(4px); }

.step-icon { font-size: 26px; flex-shrink: 0; }

.step-item p {
    font-size: 13px;
    font-weight: 700;
    color: #3a2a4a;
}

/* ── support info ── */
.support-info {
    margin-top: 24px;
    padding-top: 18px;
    border-top: 2px dashed #ffd6e8;
    text-align: center;
}
.support-info p {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-3);
    line-height: 1.8;
}

/* ── alert ── */
.alert {
    padding: 14px 16px;
    margin-bottom: 20px;
    border-radius: 16px;
    display: flex;
    align-items: flex-start;
    gap: 12px;
}
.alert-warning {
    background: #fffbe0;
    border: 2px solid #ffe980;
    color: #856404;
}
.alert-warning p { font-size: 13px; font-weight: 700; line-height: 1.5; }
.alert-icon { font-size: 20px; flex-shrink: 0; margin-top: 1px; }

/* ── misc text ── */
.success-message {
    color: #26a69a;
    font-size: 14px;
    font-weight: 800;
    text-align: center;
    margin-bottom: 12px;
}

.info-text {
    color: var(--text-2);
    font-size: 13px;
    font-weight: 600;
    text-align: center;
    margin-bottom: 10px;
}

/* ── unsubscribe ── */
.warning-text {
    color: var(--text-2);
    font-size: 14px;
    font-weight: 600;
    line-height: 1.7;
    text-align: center;
    margin-bottom: 20px;
}

.unsubscribe-info {
    margin: 24px 0;
    background: var(--pink-pale);
    border: 2px solid #ffd6e8;
    border-radius: 20px;
    padding: 4px 16px;
}

.info-item {
    display: flex;
    align-items: center;
    padding: 14px 0;
    border-bottom: 1.5px dashed #ffd6e8;
}
.info-item:last-child { border-bottom: none; }

.info-icon { font-size: 22px; margin-right: 14px; flex-shrink: 0; }

.info-item p {
    font-size: 13px;
    font-weight: 700;
    color: #3a2a4a;
}

/* ── terms ── */
.terms {
    text-align: center;
    margin-top: 22px;
    padding-top: 18px;
    border-top: 2px dashed #ffd6e8;
}
.terms p {
    color: var(--text-3);
    font-size: 11px;
    font-weight: 700;
    line-height: 2;
}
.terms a {
    color: var(--pink);
    text-decoration: none;
    font-weight: 800;
}
.terms a:hover { text-decoration: underline; }

/* ── responsive ── */
@media (max-width: 400px) {
    .subscription-card { padding: 24px 18px; }
    .subscription-card h1 { font-size: 22px; }
    .price { font-size: 44px; }
    .features { gap: 8px; }
    .logo { font-size: 30px; }
}
