/* Fonts and Global Variables */

:root {
    --bg-dark: #0a0b0c;
    /* Deep charcoal almost black */
    --text-main: #f5ece1;
    /* Creamy off-white for the main text */
    --text-muted: #9ca3af;
    --primary: #d0705a;
    /* Warm terracotta/copper from the image lines */
    --primary-light: #e48a76;
    /* Lighter copper */
    --secondary: #a8523f;
    /* Darker rust */
    --glass-bg: rgba(255, 255, 255, 0.02);
    --glass-border: rgba(255, 255, 255, 0.05);
    --glass-blur: blur(30px);
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-main);
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
    -webkit-font-smoothing: antialiased;
}

/* -------------------------------------
   Ambient Glow & Particles (JS Target)
   ------------------------------------- */
#ambient-glow {
    position: fixed;
    top: 0;
    left: 0;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(208, 112, 90, 0.12) 0%, rgba(10, 11, 12, 0) 70%);
    border-radius: 50%;
    pointer-events: none;
    z-index: 1;
    transform: translate(-50%, -50%);
    will-change: transform;
}

#particles-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 2;
}

.particle {
    position: absolute;
    background: rgba(255, 255, 255, 0.4);
    border-radius: 50%;
    animation: floatParticle linear infinite;
}

@keyframes floatParticle {
    0% {
        transform: translateY(0) translateX(0);
        opacity: 0;
    }

    10% {
        opacity: 1;
    }

    90% {
        opacity: 1;
    }

    100% {
        transform: translateY(-100vh) translateX(100px);
        opacity: 0;
    }
}

/* -------------------------------------
   Mesh Gradient Background
   ------------------------------------- */
.mesh-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    overflow: hidden;
    pointer-events: none;
}

.mesh-blob {
    position: absolute;
    filter: blur(80px);
    border-radius: 50%;
    opacity: 0.4;
    animation: floatBlob 25s infinite alternate cubic-bezier(0.4, 0, 0.2, 1);
}

.blob-1 {
    width: 60vw;
    height: 60vw;
    background: #d0705a;
    /* Copper */
    opacity: 0.15;
    top: -20%;
    left: -10%;
}

.blob-2 {
    width: 50vw;
    height: 50vw;
    background: #a8523f;
    /* Rust */
    opacity: 0.15;
    bottom: -10%;
    right: -10%;
    animation-delay: -5s;
}

.blob-3 {
    width: 40vw;
    height: 40vw;
    background: #8b7355;
    /* Warm Earth */
    opacity: 0.12;
    top: 40%;
    left: 30%;
    animation-delay: -10s;
}

@keyframes floatBlob {
    0% {
        transform: translate(0, 0) scale(1);
    }

    100% {
        transform: translate(15%, 15%) scale(1.1);
    }
}

/* -------------------------------------
   Header / Branding
   ------------------------------------- */
.premium-header {
    position: absolute;
    top: 40px;
    left: 80px;
    z-index: 20;
}

.brand-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 20px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    border-radius: 100px;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.brand-logo {
    height: 45px;
    /* Soft translucent cream/copper tone to match the new dark charcoal theme */
    filter: invert(0.9) sepia(0.2) hue-rotate(340deg) saturate(1.5) opacity(0.8);
    margin-right: 4px;
}

.brand-accent {
    font-weight: 800;
    color: var(--primary-light);
    font-size: 15px;
    letter-spacing: 1px;
    margin-left: -10px;
    margin-right: -5px;
}

.brand-text {
    font-weight: 500;
    color: var(--text-main);
    font-size: 15px;
    letter-spacing: 1px;
    padding-right: 10px;
}

/* -------------------------------------
   Layout & Hero
   ------------------------------------- */
.premium-layout {
    display: flex;
    min-height: 100vh;
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 120px 80px 80px;
    align-items: center;
    justify-content: space-between;
    gap: 60px;
    position: relative;
    z-index: 10;
}

.hero-section {
    flex: 1;
    max-width: 600px;
}

.badge {
    display: inline-block;
    padding: 4px 12px;
    background: rgba(208, 112, 90, 0.1);
    /* Soft copper background */
    border: 1px solid rgba(208, 112, 90, 0.2);
    border-radius: 100px;
    color: var(--primary-light);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.top-right-badge {
    position: absolute;
    top: 50px;
    right: 80px;
    z-index: 20;
}

.hero-title {
    font-size: clamp(48px, 5vw, 72px);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -1px;
    margin-bottom: 24px;
}

.text-gradient {
    background: linear-gradient(135deg, var(--primary-light) 0%, var(--secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
}

.hero-subtitle {
    font-size: 18px;
    line-height: 1.6;
    color: var(--text-muted);
    font-weight: 400;
}

/* -------------------------------------
   Form Section & Glass Card
   ------------------------------------- */
.form-section {
    flex: 1;
    max-width: 480px;
    display: flex;
    flex-direction: column;
    perspective: 1200px;
}

.form-header {
    margin-bottom: 24px;
}

.form-header h3 {
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 4px;
    color: #f8fafc;
}

.form-header p {
    color: var(--text-muted);
    font-size: 15px;
}

.glass-card {
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 40px;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.1);
    position: relative;
    overflow: hidden;
    transition: transform 0.1s cubic-bezier(0.2, 0.8, 0.2, 1);
    transform-style: preserve-3d;
}

.glass-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
}

/* Floating Label Inputs */
.premium-form {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.input-group {
    position: relative;
}

.input-group input,
.input-group textarea {
    width: 100%;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 24px 20px 10px;
    /* Padding for floating label */
    color: var(--text-main);
    font-size: 16px;
    font-family: 'Inter', sans-serif;
    outline: none;
    transition: all 0.3s ease;
}

.input-group textarea {
    min-height: 120px;
    resize: vertical;
}

.input-group label {
    position: absolute;
    left: 20px;
    top: 18px;
    color: var(--text-muted);
    font-size: 16px;
    pointer-events: none;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.input-group input:focus~label,
.input-group input:not(:placeholder-shown)~label,
.input-group textarea:focus~label,
.input-group textarea:not(:placeholder-shown)~label {
    top: 6px;
    font-size: 11px;
    color: var(--primary-light);
    font-weight: 500;
}

.input-border {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 16px;
    pointer-events: none;
    box-shadow: 0 0 0 2px transparent;
    transition: box-shadow 0.3s ease;
}

.input-group input:focus~.input-border,
.input-group textarea:focus~.input-border {
    box-shadow: 0 0 0 1px var(--primary-light), 0 0 20px rgba(208, 112, 90, 0.2);
}

/* Premium Button */
.premium-btn {
    position: relative;
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border: none;
    border-radius: 16px;
    color: white;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    overflow: hidden;
    transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
    margin-top: 10px;
    box-shadow: 0 10px 20px rgba(208, 112, 90, 0.2);
}

.btn-text {
    position: relative;
    z-index: 2;
}

.btn-glow {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--primary-light), var(--primary));
    opacity: 0;
    transition: opacity 0.3s;
    z-index: 1;
}

.premium-btn:hover .btn-glow {
    opacity: 1;
}

.premium-btn:active {
    transform: scale(0.96);
}

/* Ripple effect inside button */
.ripple {
    position: absolute;
    border-radius: 50%;
    transform: scale(0);
    animation: rippleAnim 0.6s linear;
    background-color: rgba(255, 255, 255, 0.4);
    z-index: 3;
    pointer-events: none;
}

@keyframes rippleAnim {
    to {
        transform: scale(4);
        opacity: 0;
    }
}

/* Animations */
.stagger-1 {
    opacity: 0;
    animation: blurReveal 1s cubic-bezier(0.16, 1, 0.3, 1) forwards 0.1s;
}

.stagger-2 {
    opacity: 0;
    animation: blurReveal 1s cubic-bezier(0.16, 1, 0.3, 1) forwards 0.2s;
}

.stagger-3 {
    opacity: 0;
    animation: blurReveal 1s cubic-bezier(0.16, 1, 0.3, 1) forwards 0.3s;
}

@keyframes blurReveal {
    from {
        opacity: 0;
        transform: translateY(20px);
        filter: blur(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
        filter: blur(0);
    }
}

/* -------------------------------------
   Legacy Fallbacks (Admin, Success)
   ------------------------------------- */
.container {
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 40px;
    width: 100%;
    max-width: 400px;
    margin: 80px auto;
    text-align: center;
    position: relative;
    z-index: 10;
}

.container h1 {
    font-size: 28px;
    font-weight: 800;
    margin-bottom: 8px;
    background: linear-gradient(135deg, var(--primary-light) 0%, var(--secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.admin-container {
    max-width: 800px;
    width: 100%;
    margin: 80px auto;
    position: relative;
    z-index: 10;
    padding: 30px 30px;
}

.header-actions {
    display: flex;
    justify-content: space-between;
    margin-bottom: 30px;
}

.prayer-grid {
    display: grid;
    gap: 20px;
}

.prayer-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    backdrop-filter: var(--glass-blur);
    border-radius: 16px;
    padding: 24px;
    transition: transform 0.2s, border-color 0.2s;
}

.prayer-card:hover {
    transform: translateY(-2px);
    border-color: var(--primary-light);
}

.prayer-header {
    display: flex;
    justify-content: space-between;
    border-bottom: 1px solid var(--glass-border);
    padding-bottom: 12px;
    margin-bottom: 12px;
}

.prayer-name {
    font-weight: 600;
    font-size: 18px;
    color: var(--text-main);
}

.prayer-date {
    font-size: 12px;
    color: var(--text-muted);
}

.prayer-phone {
    color: var(--primary-light);
    font-size: 14px;
    margin-top: 4px;
}

.prayer-body {
    white-space: pre-wrap;
    font-size: 15px;
    color: #e2e8f0;
}

.empty-state {
    text-align: center;
    padding: 40px;
    color: var(--text-muted);
}

.qr-section {
    text-align: center;
    margin-top: 30px;
    border-top: 1px solid var(--glass-border);
    padding-top: 20px;
}

.qr-section img {
    border-radius: 12px;
}

.btn-secondary {
    background: transparent;
    border: 1px solid var(--glass-border);
    color: var(--text-main);
    padding: 8px 16px;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.2s;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
}

.success-icon {
    font-size: 64px;
    text-align: center;
    display: block;
    margin-bottom: 20px;
}

/* Responsive Media Queries */
@media (max-width: 900px) {
    .premium-layout {
        flex-direction: column;
        justify-content: center;
        padding: 140px 24px 100px;
        text-align: center;
        gap: 10px;
    }

    .premium-header {
        left: 20px;
        top: 20px;
        transform: none;
    }

    .top-right-badge {
        display: none;
    }

    .brand-pill {
        padding: 6px 14px;
    }

    .brand-logo {
        height: 32px;
        margin-right: 2px;
    }

    .brand-accent,
    .brand-text {
        font-size: 14px;
    }

    .hero-title {
        text-align: center;
        font-size: clamp(32px, 8vw, 40px);
        margin-bottom: 12px;
    }

    .hero-subtitle {
        font-size: 15px;
        max-width: 340px;
        margin: 0 auto 10px;
    }

    .form-section {
        width: 100%;
        max-width: 400px;
        margin: 0 auto;
    }

    .form-header {
        display: none;
    }

    .glass-card {
        padding: 24px 20px;
    }
}