/* ═══════════════════════════════════════════════════════════
   BIRTHDAY FUN - 3D Interactive Birthday Invitation Template
   ════════════════════════════════════════════════════════════ */

:root {
    --primary: #ff6b9d;
    --secondary: #ffd93d;
    --accent: #6bcf7f;
    --blue: #4facfe;
    --purple: #a98aff;
    --bg: #fff5f8;
    --card: #ffffff;
    --text: #2d3748;
    --text-light: #718096;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Quicksand', sans-serif;
    background: var(--bg);
    color: var(--text);
    overflow-x: hidden;
}

/* ══════════════════════════════════════════════════════════
   FLOATING CONFETTI & BALLOONS
   ══════════════════════════════════════════════════════════ */
.bf-confetti, .bf-balloons {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 1;
}

/* ══════════════════════════════════════════════════════════
   CUSTOM CURSOR
   ══════════════════════════════════════════════════════════ */
.bf-cursor, .bf-cursor-trail {
    position: fixed;
    width: 20px;
    height: 20px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: 50%;
    pointer-events: none;
    z-index: 9999;
    transform: translate(-50%, -50%);
    transition: transform 0.15s ease;
}

.bf-cursor-trail {
    width: 40px;
    height: 40px;
    border: 2px solid var(--primary);
    background: transparent;
    transition: transform 0.2s ease, opacity 0.3s;
}

@media (max-width: 768px) {
    .bf-cursor, .bf-cursor-trail { display: none; }
}

/* ══════════════════════════════════════════════════════════
   NAVIGATION
   ══════════════════════════════════════════════════════════ */
.bf-nav {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 12px 24px;
    border-radius: 50px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    display: flex;
    gap: 20px;
    z-index: 100;
    opacity: 0;
    transition: opacity 0.3s, transform 0.3s;
}

.bf-nav.bf-visible {
    opacity: 1;
}

.bf-nav a {
    text-decoration: none;
    color: var(--text);
    font-weight: 600;
    font-size: 0.9rem;
    transition: color 0.3s;
}

.bf-nav a:hover {
    color: var(--primary);
}

@media (max-width: 768px) {
    .bf-nav {
        flex-direction: column;
        gap: 10px;
        padding: 15px;
    }
}

/* ══════════════════════════════════════════════════════════
   COVER CARD
   ══════════════════════════════════════════════════════════ */
.bf-cover {
    position: fixed;
    inset: 0;
    background: linear-gradient(135deg, #ff6b9d 0%, #ffd93d 50%, #6bcf7f 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999;
    cursor: pointer;
    transition: opacity 0.5s;
}

.bf-cover.bf-hidden {
    opacity: 0;
    pointer-events: none;
}

.bf-cover-inner {
    max-width: 500px;
    width: 90%;
}

.bf-cover-card {
    background: white;
    border-radius: 30px;
    padding: 50px 30px;
    text-align: center;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.2);
    transform: scale(0.95);
    animation: bfPulse 2s ease-in-out infinite;
}

@keyframes bfPulse {
    0%, 100% { transform: scale(0.95); }
    50% { transform: scale(1); }
}

.bf-cover-balloons {
    display: flex;
    justify-content: center;
    gap: 20px;
    font-size: 3rem;
    margin-bottom: 20px;
}

.bf-balloon {
    display: inline-block;
    animation: bfBalloonFloat 3s ease-in-out infinite;
    animation-delay: var(--d);
}

@keyframes bfBalloonFloat {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

.bf-cover-kepada {
    margin-bottom: 20px;
}

.bf-cover-label {
    font-size: 0.9rem;
    color: var(--text-light);
    margin-bottom: 5px;
}

.bf-guest-name {
    font-family: 'Pacifico', cursive;
    font-size: 1.5rem;
    color: var(--primary);
}

.bf-cover-divider {
    font-size: 1.5rem;
    margin: 20px 0;
}

.bf-cover-title {
    font-size: 1rem;
    color: var(--text-light);
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.bf-cover-name {
    font-family: 'Fredoka', sans-serif;
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 15px;
}

.bf-cover-age {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 15px;
}

.bf-age-label {
    font-size: 1rem;
    color: var(--text-light);
}

.bf-age-num {
    font-family: 'Fredoka', sans-serif;
    font-size: 3rem;
    font-weight: 700;
    color: var(--secondary);
    line-height: 1;
}

.bf-cover-date {
    font-size: 1.1rem;
    color: var(--text);
    margin-bottom: 30px;
    font-weight: 600;
}

.bf-cover-btn {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    border: none;
    padding: 15px 40px;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 10px 30px rgba(255, 107, 157, 0.4);
    transition: transform 0.3s, box-shadow 0.3s;
}

.bf-cover-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(255, 107, 157, 0.5);
}

/* ══════════════════════════════════════════════════════════
   MAIN CONTENT
   ══════════════════════════════════════════════════════════ */
.bf-main {
    opacity: 0;
    transition: opacity 0.5s 0.3s;
}

.bf-main.bf-visible {
    opacity: 1;
}

/* Reveal Animation */
.bf-rv {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s, transform 0.6s;
}

.bf-rv.bf-show {
    opacity: 1;
    transform: translateY(0);
}

/* ══════════════════════════════════════════════════════════
   HERO SECTION
   ══════════════════════════════════════════════════════════ */
.bf-hero {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 80px 20px 60px;
    background: linear-gradient(135deg, #ff6b9d20 0%, #ffd93d20 50%, #6bcf7f20 100%);
    position: relative;
    overflow: hidden;
}

.bf-hero-badge {
    display: inline-block;
    background: white;
    padding: 10px 25px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--primary);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
}

.bf-hero-guest {
    background: white;
    padding: 15px 30px;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    margin-bottom: 40px;
}

.bf-hero-guest-label {
    display: block;
    font-size: 0.85rem;
    color: var(--text-light);
    margin-bottom: 5px;
}

.bf-hero-guest-name {
    font-family: 'Pacifico', cursive;
    font-size: 1.3rem;
    color: var(--primary);
}

/* 3D Scene */
.bf-scene {
    position: relative;
    width: 300px;
    height: 300px;
    margin: 40px auto;
    perspective: 1000px;
}

.bf-orbit-emoji {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 50px;
    height: 50px;
    font-size: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transform-origin: 0 0;
    animation: bfOrbit 20s linear infinite;
    animation-delay: calc(var(--od) * -5s);
    transform: translate(-50%, -50%) rotate(var(--oa)) translateX(150px) rotate(calc(-1 * var(--oa)));
}

@keyframes bfOrbit {
    to { transform: translate(-50%, -50%) rotate(calc(var(--oa) + 360deg)) translateX(150px) rotate(calc(-1 * (var(--oa) + 360deg))); }
}

.bf-card-3d {
    position: relative;
    width: 200px;
    height: 200px;
    margin: 0 auto;
    transform-style: preserve-3d;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.bf-ring-outer, .bf-ring-mid {
    position: absolute;
    inset: -20px;
    border-radius: 50%;
    border: 3px solid;
    opacity: 0.3;
}

.bf-ring-outer {
    border-color: var(--primary);
    animation: bfRingSpin 20s linear infinite;
}

.bf-ring-mid {
    inset: -10px;
    border-color: var(--secondary);
    animation: bfRingSpin 15s linear infinite reverse;
}

@keyframes bfRingSpin {
    to { transform: rotate(360deg); }
}

.bf-photo-circle {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    overflow: hidden;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 20px 60px rgba(255, 107, 157, 0.3);
    position: relative;
    z-index: 1;
}

.bf-photo-circle img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.bf-names {
    margin-top: 40px;
}

.bf-hero-subtitle {
    display: block;
    font-size: 1rem;
    color: var(--text-light);
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.bf-hero-name {
    display: block;
    font-family: 'Fredoka', sans-serif;
    font-size: 3rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 10px;
}

.bf-hero-age {
    display: block;
    font-size: 1.2rem;
    color: var(--text);
    font-weight: 600;
}

.bf-datestrip {
    display: flex;
    gap: 20px;
    margin-top: 40px;
    flex-wrap: wrap;
    justify-content: center;
}

.bf-ds-block {
    background: white;
    padding: 20px;
    border-radius: 15px;
    min-width: 80px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    text-align: center;
}

.bf-ds-num {
    font-family: 'Fredoka', sans-serif;
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
    line-height: 1;
    margin-bottom: 5px;
}

.bf-ds-lbl {
    font-size: 0.8rem;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.bf-ds-sep {
    font-size: 2rem;
    color: var(--secondary);
    font-weight: 700;
}

@media (max-width: 768px) {
    .bf-hero-name { font-size: 2rem; }
    .bf-ds-block { min-width: 60px; padding: 15px; }
    .bf-ds-num { font-size: 1.5rem; }
}

/* ══════════════════════════════════════════════════════════
   SECTIONS
   ══════════════════════════════════════════════════════════ */
section {
    padding: 80px 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.bf-section-badge {
    display: inline-block;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    padding: 10px 25px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 0.9rem;
    box-shadow: 0 5px 20px rgba(255, 107, 157, 0.3);
    margin-bottom: 20px;
}

.bf-sec-title {
    font-family: 'Fredoka', sans-serif;
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 40px;
    text-align: center;
}

/* ══════════════════════════════════════════════════════════
   BIRTHDAY PERSON
   ══════════════════════════════════════════════════════════ */
.bf-person-sec {
    text-align: center;
}

.bf-person-card {
    background: white;
    border-radius: 30px;
    padding: 50px 40px;
    max-width: 500px;
    margin: 0 auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.1);
    position: relative;
    overflow: hidden;
}

.bf-card-glow {
    position: absolute;
    inset: -50%;
    background: conic-gradient(from 0deg, var(--primary), var(--secondary), var(--accent), var(--blue), var(--primary));
    animation: bfGlowRotate 4s linear infinite;
    opacity: 0.5;
    filter: blur(40px);
}

@keyframes bfGlowRotate {
    to { transform: rotate(360deg); }
}

.bf-person-avatar {
    position: relative;
    z-index: 1;
    width: 200px;
    height: 200px;
    margin: 0 auto 20px;
    border-radius: 50%;
    overflow: hidden;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    box-shadow: 0 20px 60px rgba(255, 107, 157, 0.3);
}

.bf-person-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.bf-person-age-badge {
    position: relative;
    z-index: 1;
    display: inline-block;
    background: linear-gradient(135deg, var(--secondary), var(--accent));
    color: white;
    font-family: 'Fredoka', sans-serif;
    font-size: 2rem;
    font-weight: 700;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: -40px auto 20px;
    box-shadow: 0 10px 30px rgba(255, 217, 61, 0.4);
}

.bf-person-name {
    position: relative;
    z-index: 1;
    font-family: 'Fredoka', sans-serif;
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 10px;
}

.bf-person-parent {
    position: relative;
    z-index: 1;
    font-size: 1rem;
    color: var(--text-light);
    margin-bottom: 15px;
}

.bf-person-ig {
    position: relative;
    z-index: 1;
    display: inline-block;
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    padding: 8px 20px;
    border-radius: 50px;
    border: 2px solid var(--primary);
    transition: all 0.3s;
}

.bf-person-ig:hover {
    background: var(--primary);
    color: white;
}

/* ══════════════════════════════════════════════════════════
   PARTY DETAILS
   ══════════════════════════════════════════════════════════ */
.bf-party-sec {
    text-align: center;
}

.bf-party-card {
    background: white;
    border-radius: 30px;
    padding: 50px 40px;
    max-width: 600px;
    margin: 0 auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.1);
}

.bf-party-icon {
    font-size: 4rem;
    margin-bottom: 20px;
}

.bf-party-title {
    font-family: 'Fredoka', sans-serif;
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 30px;
}

.bf-party-details {
    text-align: left;
}

.bf-detail-row {
    display: flex;
    gap: 20px;
    padding: 20px;
    background: var(--bg);
    border-radius: 15px;
    margin-bottom: 15px;
}

.bf-detail-icon {
    font-size: 2rem;
    flex-shrink: 0;
}

.bf-detail-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.bf-detail-info strong {
    color: var(--text);
    font-size: 1.1rem;
}

.bf-detail-info span {
    color: var(--text-light);
    font-size: 0.95rem;
}

/* ══════════════════════════════════════════════════════════
   COUNTDOWN
   ══════════════════════════════════════════════════════════ */
.bf-cd-sec {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    padding: 60px 20px;
    text-align: center;
}

.bf-cd-label {
    color: white;
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 30px;
}

.bf-cd-grid {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

.bf-cd-block {
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 25px 20px;
    min-width: 100px;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.bf-cd-num {
    display: block;
    font-family: 'Fredoka', sans-serif;
    font-size: 3rem;
    font-weight: 700;
    color: white;
    line-height: 1;
    margin-bottom: 10px;
}

.bf-cd-unit {
    display: block;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.9);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.bf-cd-sep {
    font-size: 2.5rem;
    color: white;
    font-weight: 700;
    display: flex;
    align-items: center;
}

@media (max-width: 768px) {
    .bf-cd-block { min-width: 70px; padding: 20px 15px; }
    .bf-cd-num { font-size: 2rem; }
    .bf-cd-sep { font-size: 1.5rem; }
}

/* ══════════════════════════════════════════════════════════
   LOCATION
   ══════════════════════════════════════════════════════════ */
.bf-loc-sec {
    text-align: center;
}

.bf-loc-name {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 30px;
}

.bf-map-card {
    background: white;
    border-radius: 30px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
}

.bf-map-card iframe {
    width: 100%;
    height: 400px;
    border: none;
}

.bf-map-placeholder {
    width: 100%;
    height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg);
}

.bf-maps-btn {
    display: inline-block;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    padding: 15px 40px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 700;
    box-shadow: 0 10px 30px rgba(255, 107, 157, 0.3);
    transition: transform 0.3s, box-shadow 0.3s;
}

.bf-maps-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(255, 107, 157, 0.4);
}

/* ══════════════════════════════════════════════════════════
   GALLERY
   ══════════════════════════════════════════════════════════ */
.bf-gallery-sec {
    text-align: center;
}

.bf-gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.bf-gallery-item {
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s, box-shadow 0.3s;
}

.bf-gallery-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.bf-gallery-item img {
    width: 100%;
    height: 300px;
    object-fit: cover;
}

/* ══════════════════════════════════════════════════════════
   RSVP
   ══════════════════════════════════════════════════════════ */
.bf-rsvp-sec {
    text-align: center;
}

.bf-rsvp-note {
    font-size: 1.1rem;
    color: var(--text-light);
    margin-bottom: 40px;
}

.bf-form-card {
    background: white;
    border-radius: 30px;
    padding: 50px 40px;
    max-width: 600px;
    margin: 0 auto 50px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.1);
}

.bf-form-field {
    margin-bottom: 25px;
    text-align: left;
}

.bf-form-field label {
    display: block;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 10px;
}

.bf-form-field input,
.bf-form-field select,
.bf-form-field textarea {
    width: 100%;
    padding: 15px;
    border: 2px solid #e2e8f0;
    border-radius: 15px;
    font-family: 'Quicksand', sans-serif;
    font-size: 1rem;
    transition: border-color 0.3s;
}

.bf-form-field input:focus,
.bf-form-field select:focus,
.bf-form-field textarea:focus {
    outline: none;
    border-color: var(--primary);
}

.bf-attend-opts {
    display: flex;
    gap: 15px;
}

.bf-attend-opt {
    flex: 1;
    padding: 15px;
    border: 2px solid #e2e8f0;
    border-radius: 15px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
}

.bf-attend-opt span:first-child {
    display: block;
    font-size: 2rem;
    margin-bottom: 5px;
}

.bf-attend-opt.bf-active {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    border-color: transparent;
}

.bf-submit {
    width: 100%;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    border: none;
    padding: 18px;
    border-radius: 15px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 10px 30px rgba(255, 107, 157, 0.3);
    transition: transform 0.3s, box-shadow 0.3s;
}

.bf-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 40px rgba(255, 107, 157, 0.4);
}

.bf-rsvp-ok {
    text-align: center;
    padding: 40px 20px;
}

.bf-ok-icon {
    font-size: 4rem;
    display: block;
    margin-bottom: 20px;
}

.bf-ok-text {
    font-family: 'Fredoka', sans-serif;
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 10px;
}

.bf-ok-sub {
    font-size: 1.1rem;
    color: var(--text-light);
}

/* Wishes */
.bf-wishes {
    max-width: 800px;
    margin: 0 auto;
}

.bf-wishes-title {
    font-family: 'Fredoka', sans-serif;
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 30px;
}

.bf-wish-bubble {
    background: white;
    border-radius: 20px;
    padding: 25px;
    margin-bottom: 20px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
    text-align: left;
}

.bf-wish-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.bf-wish-name {
    font-weight: 700;
    color: var(--primary);
    font-size: 1.1rem;
}

.bf-wish-status {
    font-size: 0.9rem;
}

.bf-wish-msg {
    color: var(--text);
    line-height: 1.6;
}

/* ══════════════════════════════════════════════════════════
   FOOTER
   ══════════════════════════════════════════════════════════ */
.bf-footer {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    padding: 60px 20px;
    text-align: center;
    color: white;
}

.bf-footer-emoji {
    font-size: 2rem;
    margin-bottom: 20px;
}

.bf-footer-name {
    font-family: 'Fredoka', sans-serif;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 15px;
}

.bf-footer-date {
    font-size: 1.2rem;
    margin-bottom: 15px;
    opacity: 0.9;
}

.bf-footer-note {
    font-size: 1.1rem;
    margin-bottom: 30px;
    opacity: 0.9;
}

.bf-footer-credit {
    font-size: 0.9rem;
    opacity: 0.7;
}
