/**
 * HappMe Public Card Styles
 *
 * Standalone stylesheet for the public-facing HappMe card page (single-happme.php).
 * This page uses its own HTML shell (no WordPress header/footer).
 */

.happme-body { font-family: 'Satoshi', sans-serif; background: #F1F1E5; min-height: 100vh; display: flex; flex-direction: column; align-items: center; }
.happme-body * { margin: 0; padding: 0; box-sizing: border-box; }

.happme-page { width: 100%; max-width: 430px; min-height: 100vh; display: flex; flex-direction: column; align-items: center; padding: 0 16px; perspective: 1200px; }

/* Hero background */
.happme-hero {
    position: fixed; top: 0; left: 0; width: 100%; height: 45vh;
    background-size: cover; background-position: center;
    filter: blur(20px) brightness(0.7); -webkit-filter: blur(20px) brightness(0.7);
    transform: scale(1.1); z-index: 0;
}

/* Card */
.happme-card-container {
    position: relative; z-index: 1;
    width: 100%; margin-top: 20px;
    border-radius: 16px; overflow: hidden;
    box-shadow: 0 8px 40px rgba(0,0,0,0.12);
    transform-style: preserve-3d;
}
.happme-card-inner {
    background-color: #FEFFF6;
    background-size: cover;
    background-blend-mode: overlay;
    position: relative;
    min-height: 520px;
}
.happme-slide { padding: 24px 20px; height: 600px; display: flex; flex-direction: column; overflow: hidden; }
.happme-slide[data-slide="1"] { display: none; }

/* Powered by */
.happme-powered { text-align: center; font-family: 'Courier Prime', monospace; font-size: 11px; letter-spacing: 3px; text-transform: uppercase; color: #171A27; margin-bottom: 12px; display: flex; align-items: center; justify-content: center; gap: 6px; }
.happme-powered img { height: 14px; }

/* Dotted separator */
.happme-separator { border: none; border-top: 2px dashed #D1D0C8; margin: 0 0 12px 0; }

/* Header text */
.happme-header-text { position: relative; margin-bottom: 12px; }
.happme-title { font-family: 'Clash Display', sans-serif; font-weight: 700; font-size: 52px; line-height: 0.9; color: #171A27; letter-spacing: -1px; margin: 0 0 -5px;}
.happme-lets-create { font-family: 'Reenie Beanie', cursive; font-size: 30px; color: #171A27; position: absolute; top: 0; right: 0; transform: rotate(7deg); }

/* Photo area */
.happme-photo-wrap { position: relative; margin-bottom: 16px; }
.happme-photo-frame { border-radius: 4px; padding: 0; overflow: hidden; }
.happme-photo-frame img {  display: block; }
.happme-photo-frame img.main-img {  width: 100%;   height: 280px;
    object-fit: cover;
    object-position: center; }

/* Sticker overlay */
.happme-sticker { position: absolute; width: 75px; height: 75px; pointer-events: none; }

/* Info */
.happme-info { padding-top: 8px; }
.happme-info-label { font-family: 'Courier Prime', monospace; font-size: 12px; letter-spacing: 2px; text-transform: uppercase; color: #555; display: inline; }
.happme-info-value { font-family: 'Reenie Beanie', cursive; font-size: 28px; color: #171A27; margin-left: 4px; border-bottom: 1px dashed #D1D0C8; display: inline; flex: 1; }
.happme-info-row { margin-bottom: 4px; display: flex; align-items: baseline; }
.happme-info-row:first-child .happme-info-value { padding-left: 25px; }
.happme-info-row:last-child .happme-info-value { padding-left: 10px; }

/* QR slide */
.happme-qr-wrap { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.happme-qr-code { margin: 20px 0; }
.happme-qr-code canvas, .happme-qr-code img { border-radius: 8px; }
.happme-scan-text { font-family: 'Reenie Beanie', cursive; font-size: 32px; color: #171A27; text-align: center; margin-bottom: 20px; }

/* Share buttons inside card */
.happme-card-share { display: flex; justify-content: center; gap: 20px; padding-top: 16px; border-top: 2px dashed #D1D0C8; margin-top: auto; }
.happme-card-share a, .happme-card-share button { display: flex; flex-direction: column; align-items: center; gap: 6px; background: none; border: none; cursor: pointer; text-decoration: none; color: #171A27; padding: 0;}
.happme-card-share .share-icon { width: 48px; height: 48px; border-radius: 50%; border: 1px solid #E8E6F0; display: flex; align-items: center; justify-content: center; }
.happme-card-share .share-icon img { width: 20px; height: 20px; }
.happme-card-share .share-label { font-size: 11px; color: #555; }

/* Dots */
.happme-dots { display: flex; justify-content: center; gap: 8px; padding: 12px 0; }
.happme-dots .dot { width: 8px; height: 8px; border-radius: 50%; background: #D1D0C8; cursor: pointer; transition: background 0.2s; }
.happme-dots .dot.active { background: #171A27; }

/* CTA */
.happme-cta { width: 100%; max-width: 400px; padding: 18px; margin: 0px 0 12px; background: #171A27; color: #fff; border: none; border-radius: 50px; font-family: 'Satoshi', sans-serif; font-size: 17px; font-weight: 500; cursor: pointer; letter-spacing: 0.3px; }

/* Social row */
.happme-socials { display: flex; justify-content: center; gap: 16px; padding: 8px 0 30px; }
.happme-socials a { display: flex; align-items: center; justify-content: center; width: 36px; height: 36px; opacity: 0.6; transition: opacity 0.2s; }
.happme-socials a:hover { opacity: 1; }
.happme-socials img { width: 22px; height: 22px; filter: brightness(0); }

/* Lead form popup */
.happme-form-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.4); z-index: 9999; display: none; }
.happme-form-popup { position: fixed; bottom: 0; left: 0; width: 100%; max-height: 85vh; background: #fff; border-radius: 20px 20px 0 0; z-index: 10000; display: none; flex-direction: column; overflow-y: auto; animation: slideFormUp 0.3s ease; }
@keyframes slideFormUp { from { transform: translateY(100%); } to { transform: translateY(0); } }
.happme-form-popup.is-open { display: flex; }
.happme-form-overlay.is-open { display: block; }
.happme-body.form-open { overflow: hidden; }

.happme-form-hero { position: relative; height: 180px; background-size: cover; background-position: center; border-radius: 20px 20px 0 0; overflow: hidden; }
.happme-form-hero::after { content: ''; position: absolute; bottom: 0; left: 0; width: 100%; height: 80px; background: linear-gradient(transparent, #fff); }

.happme-form-content { padding: 20px 24px 80px; }
.happme-form-step { display: none; }
.happme-form-step.active { display: block; }

.happme-form-title { font-family: 'Clash Display', sans-serif; font-size: 26px; font-weight: 600; line-height: 1.2; margin-bottom: 6px; color: #171A27; }
.happme-form-subtitle { font-size: 14px; color: #786092; margin-bottom: 20px; }

/* Service cards in form */
.happme-service-card { display: flex; align-items: center; gap: 20px; padding: 16px; margin-bottom: 10px; background: #F7F7FC; border-radius: 12px; border: 2px solid transparent; cursor: pointer; transition: all 0.2s; }
.happme-service-card.selected { background: #EEEDFA; border-color: #786092; }
.happme-service-card input[type="checkbox"] { display: none; }
.happme-service-check { width: 24px; height: 24px; border-radius: 6px; border: 2px solid #D1D0DB; display: flex; align-items: center; justify-content: center; flex-shrink: 0; transition: all 0.2s; }
.happme-service-card.selected .happme-service-check { background: #786092; border-color: #786092; }
.happme-service-card.selected .happme-service-check::after { content: ''; display: block; width: 6px; height: 10px; border: solid #fff; border-width: 0 2px 2px 0; transform: rotate(45deg); margin-top: -2px; }
.happme-service-name { font-size: 15px; margin: 0 0 6px; font-weight: 500; color: #171A27; line-height: 1; }
.happme-service-brief { font-size: 13px; color: #786092; margin-top: 2px; }

/* Other service */
.happme-other-input { display: none; margin-top: 10px; padding: 12px 16px; width: 100%; background: #F7F7FC; border: 1px solid #E8E6F0; border-radius: 10px; font-size: 14px; }
.happme-other-input.show { display: block; }

/* Form fields */
.happme-field { margin-bottom: 14px; }
.happme-field label { display: block; font-size: 13px; font-weight: 500; color: #171A27; margin-bottom: 4px; }
.happme-field .required-star { color: #dc2626; }
.happme-field input { width: 100%; height: 46px; padding: 0 14px; background: #F7F7FC; border: 1px solid #E8E6F0; border-radius: 10px; font-size: 15px; color: #171A27; }
.happme-field input:focus { outline: none; border-color: #786092; background: #fff; }
.happme-field .phone-wrap { display: flex; border: 1px solid #E8E6F0; border-radius: 10px; overflow: hidden; background: #F7F7FC; }
.happme-field .phone-prefix { display: flex; align-items: center; padding: 0 12px; font-weight: 600; background: #EEEDFA; border-right: 1px solid #E8E6F0; font-size: 15px; }
.happme-field .phone-wrap input { border: none; border-radius: 0; }
.happme-field .tax-hint { font-size: 11px; color: #786092; text-align: right; }

/* Form footer */
.happme-form-footer { position: sticky; bottom: 0; display: flex; justify-content: space-between; align-items: center; padding: 16px 24px; border-top: 1px solid #E8E6F0; background: #fff; z-index: 10; }
.happme-form-back { display: flex; align-items: center; gap: 6px; background: none; border: none; font-size: 15px; color: #171A27; cursor: pointer; }
.happme-form-back svg { width: 8px; }
.happme-form-next { padding: 14px 40px; background: #171A27; color: #fff; border: none; border-radius: 50px; font-size: 16px; font-weight: 500; cursor: pointer; }

/* Thank you */
.happme-thankyou { text-align: center; padding: 40px 20px; }
.happme-thankyou-icon { width: 60px; height: 60px; margin: 0 auto 16px; background: #EEEDFA; border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.happme-thankyou-icon svg { width: 28px; height: 28px; stroke: #786092; }
.happme-thankyou h2 { font-family: 'Clash Display', sans-serif; font-size: 28px; font-weight: 600; margin-bottom: 12px; }
.happme-thankyou p { font-size: 14px; color: #555; line-height: 1.6; margin-bottom: 24px; }
.happme-thankyou .contact-btn { display: inline-block; padding: 14px 40px; background: #171A27; color: #fff; border: none; border-radius: 50px; font-size: 16px; cursor: pointer; text-decoration: none; }

/* HAPP promo */
.happme-promo { display: flex; align-items: center; gap: 12px; margin: 24px 0 0; padding: 16px; background: #171A27; border-radius: 12px; cursor: pointer; text-decoration: none; color: #fff; }
.happme-promo-icon { width: 36px; height: 36px; flex-shrink: 0; }
.happme-promo-text { flex: 1; }
.happme-promo-title { font-size: 14px; font-weight: 600; }
.happme-promo-subtitle { font-size: 12px; opacity: 0.7; }
.happme-promo-arrow { font-size: 20px; opacity: 0.5; }

/* Error */
.happme-field.has-error input { border-color: #dc2626; }
.happme-field-error { font-size: 12px; color: #dc2626; margin-top: 4px; }
