/**
 * Happy Parenting Network Frontend Styles (Brand Edition: Gembira Parenting Palette)
 * Style: Warm white background, bright sunshine yellow & gold, royal & sky blue, playful watermelon red, mint green
 * Target: 80% Smartphone Users (Modern Moms Community)
 */

/* =========================================================
   1. Global Colors & Base Styling
   ========================================================= */
:root {
    --hpn-bg-cream: #FCFAF6;
    --hpn-white: #FFFFFF;
    --hpn-yellow: #FFC400;
    --hpn-yellow-gold: #FFA000;
    --hpn-yellow-soft: #FFF9E6;
    --hpn-blue-primary: #0077C8;
    --hpn-blue-dark: #004B87;
    --hpn-blue-cyan: #00A3E0;
    --hpn-blue-soft: #E8F5FE;
    --hpn-red-gembira: #FF334B;
    --hpn-green-mint: #2CD584;
    --hpn-text-dark: #1E293B;
    --hpn-text-muted: #64748B;
}

/* Auth Container */
.woocommerce-account .woocommerce {
    max-width: 520px;
    margin: 0 auto;
    padding: 10px 15px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
}

.woocommerce-account .u-columns.col2-set {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 10px 0 25px;
}

.woocommerce-account .u-column1,
.woocommerce-account .u-column2 {
    width: 100% !important;
    max-width: 480px !important;
    background: #FFFFFF;
    border: 2px solid #FFF1C5;
    border-radius: 24px;
    padding: 26px 22px;
    box-shadow: 0 10px 30px -5px rgba(255, 160, 0, 0.12);
    margin: 0 auto;
}

/* Playful Rounded Headings */
.woocommerce-account h2 {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--hpn-blue-dark);
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 10px;
    letter-spacing: -0.3px;
}

.woocommerce-account h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 5px;
    background: linear-gradient(90deg, #FFC400, #FF334B);
    border-radius: 10px;
}

/* Dedicated Register Back Link */
.hpn-auth-header-mobile {
    max-width: 480px;
    margin: 0 auto 15px;
    width: 100%;
}
.hpn-back-to-login {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--hpn-blue-primary) !important;
    text-decoration: none;
    padding: 8px 14px;
    background: var(--hpn-blue-soft);
    border: 1px solid #BAE6FD;
    border-radius: 20px;
}

/* Big Mobile Touch Inputs */
.woocommerce form .form-row {
    margin-bottom: 16px;
    padding: 0;
}

.woocommerce form .form-row label {
    display: block;
    font-weight: 700;
    color: #334155;
    margin-bottom: 6px;
    font-size: 0.92rem;
}

.woocommerce form .form-row input.input-text,
.woocommerce form .form-row input[type="tel"],
.woocommerce form .form-row input[type="email"],
.woocommerce form .form-row input[type="password"] {
    width: 100% !important;
    box-sizing: border-box;
    border: 1.8px solid #E2E8F0;
    border-radius: 14px;
    padding: 14px 16px;
    font-size: 1rem;
    background: #FCFCFD;
    transition: all 0.2s ease;
    -webkit-appearance: none;
}

.woocommerce form .form-row input.input-text:focus,
.woocommerce form .form-row input[type="tel"]:focus,
.woocommerce form .form-row input[type="email"]:focus,
.woocommerce form .form-row input[type="password"]:focus {
    border-color: var(--hpn-blue-cyan);
    background: #FFFFFF;
    outline: none;
    box-shadow: 0 0 0 3px rgba(0, 163, 224, 0.2);
}

/* Submit Button: Royal Blue with Playful Feel */
.woocommerce button.button.woocommerce-button,
.woocommerce button.button.woocommerce-form-login__submit,
.woocommerce button.button.woocommerce-form-register__submit {
    background: linear-gradient(135deg, #0077C8 0%, #004B87 100%) !important;
    color: #FFFFFF !important;
    font-size: 1.05rem !important;
    font-weight: 800 !important;
    padding: 14px 20px !important;
    border-radius: 14px !important;
    width: 100% !important;
    min-height: 52px;
    margin-top: 15px;
    border: none !important;
    box-shadow: 0 6px 18px rgba(0, 119, 200, 0.35);
    cursor: pointer;
    text-align: center;
}

.woocommerce button.button:active {
    transform: scale(0.98);
}

.woocommerce-LostPassword {
    margin-top: 14px;
    text-align: center;
    font-size: 0.88rem;
}
.woocommerce-LostPassword a {
    color: var(--hpn-text-muted);
}

/* =========================================================
   2. Gembira Yellow Register CTA Card (Separated from Login)
   ========================================================= */
.hpn-register-cta-wrapper {
    max-width: 480px;
    margin: 25px auto 40px;
    width: 100%;
}

.hpn-register-cta-card {
    background: linear-gradient(145deg, #FFFDF5 0%, #FFF9E6 100%);
    border: 2px dashed #FFC400;
    border-radius: 24px;
    padding: 26px 20px;
    text-align: center;
    box-shadow: 0 6px 20px rgba(255, 196, 0, 0.15);
}

.hpn-cta-badge {
    display: inline-block;
    background: #FF334B;
    color: #FFFFFF;
    font-size: 0.72rem;
    font-weight: 800;
    padding: 5px 14px;
    border-radius: 20px;
    letter-spacing: 0.5px;
    margin-bottom: 12px;
    box-shadow: 0 2px 8px rgba(255, 51, 75, 0.3);
}

.hpn-cta-title {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--hpn-blue-dark);
    margin: 0 0 8px;
    line-height: 1.3;
}

.hpn-cta-desc {
    font-size: 0.88rem;
    color: #475569;
    line-height: 1.5;
    margin: 0 0 20px;
}

/* Register Button: Vibrant Yellow/Gold Button */
.hpn-btn-register-cta {
    display: block !important;
    width: 100% !important;
    box-sizing: border-box;
    background: linear-gradient(135deg, #FFC400 0%, #FFA000 100%) !important;
    color: #3E2400 !important;
    font-size: 1rem !important;
    font-weight: 800 !important;
    padding: 15px 16px !important;
    border-radius: 14px !important;
    text-decoration: none !important;
    text-align: center;
    box-shadow: 0 6px 18px rgba(255, 160, 0, 0.35);
    min-height: 52px;
    line-height: 1.3;
    border: none !important;
}

.hpn-reg-benefit-pill {
    background: #FFF9E6;
    border: 1px solid #FFE082;
    color: #B45309;
    padding: 10px 14px;
    border-radius: 12px;
    font-size: 0.82rem;
    font-weight: 700;
    margin: 15px 0 5px;
    text-align: center;
}

/* =========================================================
   3. Nudge Banner (Pancingan Data)
   ========================================================= */
.hpn-nudge-banner {
    background: linear-gradient(135deg, #FFFDF5 0%, #FFF9E6 100%);
    border: 2px dashed #FFC400;
    border-radius: 20px;
    padding: 22px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 25px;
    text-align: left;
}

.hpn-nudge-icon {
    font-size: 2.2rem;
    line-height: 1;
}

.hpn-nudge-title {
    margin: 0 0 6px;
    color: var(--hpn-blue-dark);
    font-size: 1.2rem;
    font-weight: 800;
}

.hpn-nudge-text {
    margin: 0 0 14px;
    color: #475569;
    font-size: 0.9rem;
    line-height: 1.5;
}

.hpn-nudge-btn {
    background: linear-gradient(135deg, #0077C8 0%, #004B87 100%) !important;
    color: #FFFFFF !important;
    border-radius: 12px !important;
    padding: 12px 18px !important;
    font-size: 0.92rem !important;
    font-weight: 700 !important;
    text-align: center;
    display: block !important;
    width: 100% !important;
    box-sizing: border-box;
}

/* =========================================================
   4. Edit Account Details (Chips & Form)
   ========================================================= */
.hpn-edit-fieldset {
    background: #FFFFFF;
    border: 2px solid #FFF1C5;
    border-radius: 20px;
    padding: 22px 18px;
    margin: 25px 0;
    box-shadow: 0 4px 15px rgba(255, 196, 0, 0.08);
}

.hpn-edit-legend {
    font-weight: 800;
    color: var(--hpn-blue-dark);
    font-size: 1.15rem;
    padding: 0 10px;
}

.hpn-edit-subtext {
    color: var(--hpn-text-muted);
    font-size: 0.85rem;
    margin-bottom: 16px;
}

.hpn-member-id-pill {
    display: inline-block;
    background: #E8F5FE;
    color: var(--hpn-blue-dark);
    border: 1px solid #BAE6FD;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.88rem;
    margin-bottom: 16px;
    font-weight: 800;
}

.hpn-child-card-edit {
    background: #FFFDF5;
    border: 1.5px solid #FFE082;
    border-radius: 16px;
    padding: 16px;
    margin: 15px 0;
}

.hpn-child-header {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #B45309;
    margin-bottom: 10px;
    font-size: 0.95rem;
}

.hpn-checkbox-chips-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}

.hpn-chip-label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #F8FAFC;
    border: 1.5px solid #CBD5E1;
    padding: 10px 14px;
    border-radius: 20px;
    font-size: 0.85rem;
    color: #334155;
    cursor: pointer;
    width: 100%;
    box-sizing: border-box;
    transition: all 0.2s ease;
}

.hpn-chip-label.checked,
.hpn-chip-label:has(input:checked) {
    background: #E8F5FE;
    border-color: var(--hpn-blue-primary);
    color: var(--hpn-blue-dark);
    font-weight: 700;
}

/* =========================================================
   5. Membership ID Card (Gembira Festive Style)
   ========================================================= */
.hpn-id-card {
    width: 100%;
    max-width: 480px;
    background: #FFFFFF;
    border: 3px solid #FFC400;
    border-radius: 24px;
    box-shadow: 0 12px 30px rgba(255, 160, 0, 0.2);
    overflow: hidden;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: #1E293B;
    margin: 15px auto;
}

.hpn-card-topbar {
    background: linear-gradient(135deg, #0077C8 0%, #004B87 100%);
    color: #FFF;
    padding: 14px 18px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 3px solid #FFC400;
}

.hpn-card-brand {
    display: flex;
    align-items: center;
    gap: 10px;
}

.hpn-card-icon {
    font-size: 1.6rem;
}

.hpn-card-title {
    font-size: 0.95rem;
    font-weight: 800;
    letter-spacing: 0.5px;
}

.hpn-card-tagline {
    font-size: 0.7rem;
    color: #E0F2FE;
}

.hpn-card-badge-vip {
    background: linear-gradient(135deg, #FFC400, #FFA000);
    color: #3E2400;
    font-size: 0.72rem;
    font-weight: 900;
    padding: 4px 10px;
    border-radius: 14px;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.15);
}

.hpn-card-body {
    padding: 18px;
    display: flex;
    flex-direction: column;
    gap: 15px;
    background: linear-gradient(180deg, #FFFFFF 0%, #FFFDF8 100%);
}

@media (min-width: 480px) {
    .hpn-card-body {
        flex-direction: row;
        justify-content: space-between;
    }
    .hpn-chip-label {
        width: auto;
    }
}

.hpn-card-left {
    flex: 1;
}

.hpn-card-field {
    margin-bottom: 10px;
}

.hpn-label {
    display: block;
    font-size: 0.7rem;
    color: #64748B;
    text-transform: uppercase;
    font-weight: 700;
}

.hpn-value {
    font-size: 0.95rem;
    font-weight: 800;
    color: #0F172A;
}

.hpn-id-code {
    color: #0077C8;
    font-size: 1.1rem;
    font-weight: 900;
}

.hpn-card-child-box {
    background: #FFF9E6;
    border: 1.5px dashed #FFC400;
    padding: 10px 14px;
    border-radius: 12px;
    margin-top: 8px;
}
.hpn-card-child-box .hpn-label {
    color: #B45309;
}

.hpn-card-right {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    border-top: 1px dashed #FFE082;
    padding-top: 14px;
}

@media (min-width: 480px) {
    .hpn-card-right {
        border-top: none;
        padding-top: 0;
        width: 110px;
    }
}

.hpn-card-qr-box {
    background: #FFF;
    padding: 6px;
    border: 2px solid #FFE082;
    border-radius: 12px;
    margin-bottom: 8px;
}

.hpn-card-status {
    font-size: 0.78rem;
    font-weight: 800;
    color: #059669;
    display: flex;
    align-items: center;
    gap: 4px;
}

.hpn-status-dot {
    width: 8px;
    height: 8px;
    background: #10B981;
    border-radius: 50%;
    display: inline-block;
}

.hpn-card-since {
    font-size: 0.7rem;
    color: #94A3B8;
    margin-top: 4px;
}

.hpn-card-footer {
    background: #FFFDF5;
    border-top: 1px solid #FFE082;
    padding: 8px 18px;
    font-size: 0.72rem;
    color: #64748B;
    display: flex;
    justify-content: space-between;
}

.hpn-action-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 15px;
}

@media (min-width: 480px) {
    .hpn-action-buttons {
        flex-direction: row;
    }
}

.hpn-btn-primary, .hpn-btn-secondary {
    width: 100% !important;
    text-align: center;
    padding: 12px !important;
    border-radius: 12px !important;
    font-weight: 800 !important;
}

.hpn-btn-primary {
    background: linear-gradient(135deg, #0077C8 0%, #004B87 100%) !important;
    color: #FFF !important;
    border: none !important;
}

.hpn-btn-secondary {
    background: #FFFFFF !important;
    color: #334155 !important;
    border: 2px solid #E2E8F0 !important;
}

/* =========================================================
   6. Pricing & Badges
   ========================================================= */
.hpn-badge {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 800;
    padding: 4px 10px;
    border-radius: 8px;
    text-transform: uppercase;
    vertical-align: middle;
}

/* Save badge: Gembira Red */
.hpn-badge-save {
    background-color: #FF334B;
    color: #FFFFFF;
}

/* Teaser badge: Gembira Yellow */
.hpn-badge-teaser {
    background-color: #FFF9E6;
    color: #B45309;
    border: 1.5px solid #FFC400;
}

/* Double Points: Vibrant Gold */
.hpn-badge-double-points {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 9;
    background: linear-gradient(135deg, #FFC400 0%, #FFA000 100%);
    color: #3E2400;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 900;
    box-shadow: 0 3px 10px rgba(255, 160, 0, 0.4);
}

.hpn-member-teaser {
    margin-top: 6px;
    font-size: 0.85rem;
}
.hpn-teaser-link {
    color: var(--hpn-blue-primary) !important;
    font-weight: 700;
    text-decoration: underline;
    margin-left: 4px;
}

/* =========================================================
   7. Gamification Points Card
   ========================================================= */
.hpn-points-card-highlight {
    background: linear-gradient(135deg, #0077C8 0%, #004B87 100%);
    color: #FFF;
    border-radius: 20px;
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 18px;
    margin-bottom: 25px;
    box-shadow: 0 10px 25px -4px rgba(0, 119, 200, 0.35);
    border-bottom: 4px solid #FFC400;
}

.hpn-points-number {
    font-size: 2.2rem;
    font-weight: 900;
    line-height: 1.1;
    color: #FFC400;
}

.hpn-tier-box {
    background: #FFF;
    border: 2px solid #FFF1C5;
    border-radius: 16px;
    padding: 20px;
    text-align: center;
    transition: all 0.2s ease;
}

.hpn-tier-box.available {
    border-color: #FFC400;
    box-shadow: 0 6px 18px rgba(255, 196, 0, 0.15);
}

.hpn-tier-points {
    font-size: 1.1rem;
    font-weight: 900;
    color: #B45309;
}

.hpn-tier-amount {
    font-size: 1.4rem;
    font-weight: 900;
    color: #0077C8;
    margin: 5px 0;
}

.hpn-btn-redeem {
    width: 100%;
    background: linear-gradient(135deg, #0077C8 0%, #004B87 100%) !important;
    color: #FFF !important;
    border-radius: 10px !important;
    font-weight: 800 !important;
    border: none !important;
}

/* Print CSS */
@media print {
    body * {
        visibility: hidden !important;
    }
    #hpn-printable-card-area, #hpn-printable-card-area * {
        visibility: visible !important;
    }
    #hpn-printable-card-area {
        position: absolute !important;
        left: 0 !important;
        top: 0 !important;
        width: 100% !important;
    }
    .hpn-action-buttons, .woocommerce-MyAccount-navigation {
        display: none !important;
    }
}
