/* ========================================
   FuzeNet Worship - Modern Glassmorphism UI
   ======================================== */

/* --- Reset & Base --- */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #6366f1;
    --primary-light: #818cf8;
    --primary-dark: #4f46e5;
    --accent: #f59e0b;
    --accent-light: #fbbf24;
    --bg-deep: #0f0e17;
    --bg-mid: #1a1932;
    --glass-bg: rgba(255, 255, 255, 0.06);
    --glass-border: rgba(255, 255, 255, 0.1);
    --glass-hover: rgba(255, 255, 255, 0.12);
    --text-primary: #fffffe;
    --text-secondary: rgba(255, 255, 255, 0.7);
    --text-muted: rgba(255, 255, 255, 0.45);
    --success: #10b981;
    --danger: #ef4444;
    --radius: 20px;
    --radius-sm: 12px;
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    --glow-primary: 0 0 30px rgba(99, 102, 241, 0.3);
    --glow-accent: 0 0 30px rgba(245, 158, 11, 0.3);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, 'Roboto', sans-serif;
    background: var(--bg-deep);
    color: var(--text-primary);
    min-height: 100vh;
    overflow-x: hidden;
    line-height: 1.6;
}

/* --- Animated Background --- */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    background:
        radial-gradient(ellipse 80% 60% at 20% 10%, rgba(99, 102, 241, 0.15) 0%, transparent 60%),
        radial-gradient(ellipse 60% 80% at 80% 90%, rgba(245, 158, 11, 0.08) 0%, transparent 60%),
        radial-gradient(ellipse 50% 50% at 50% 50%, rgba(168, 85, 247, 0.06) 0%, transparent 70%);
    z-index: -1;
    animation: bgShift 20s ease-in-out infinite alternate;
}

@keyframes bgShift {
    0% { opacity: 1; }
    50% { opacity: 0.7; }
    100% { opacity: 1; }
}

/* --- Container --- */
.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 2rem 1.5rem 6rem;
}

@media (min-width: 768px) {
    .container { padding: 3rem 2rem 6rem; }
}

/* --- Header --- */
header {
    text-align: center;
    margin-bottom: 2rem;
    padding: 2.5rem 2rem;
    background: var(--glass-bg);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    position: relative;
    overflow: hidden;
}

header::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: conic-gradient(from 0deg, transparent, rgba(99, 102, 241, 0.05), transparent, rgba(245, 158, 11, 0.03), transparent);
    animation: headerRotate 30s linear infinite;
}

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

header h1 {
    font-size: 2.4rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary-light), var(--accent-light), var(--primary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    position: relative;
    margin-bottom: 0.3rem;
    letter-spacing: -0.5px;
}

header .subtitle {
    color: var(--text-secondary);
    font-size: 1.05rem;
    font-weight: 400;
    position: relative;
}

@media (min-width: 768px) {
    header { padding: 3rem; margin-bottom: 3rem; }
    header h1 { font-size: 3rem; }
}

/* --- Navigation --- */
.nav-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 2rem;
    padding: 0.5rem;
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

@media (min-width: 768px) {
    .nav-tabs { gap: 0.75rem; padding: 0.6rem; }
}

.nav-tab {
    flex: 1;
    min-width: 80px;
    text-align: center;
    text-decoration: none;
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 0.9rem;
    padding: 0.8rem 1rem;
    border-radius: var(--radius-sm);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
    position: relative;
}

@media (min-width: 768px) {
    .nav-tab { font-size: 0.95rem; padding: 0.9rem 1.3rem; }
}

.nav-tab:hover {
    color: var(--text-primary);
    background: var(--glass-hover);
    transform: translateY(-1px);
}

.nav-tab.active {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    box-shadow: var(--glow-primary);
    transform: none;
}

/* --- Sections --- */
.section {
    margin-bottom: 2rem;
}

.section-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* --- Glass Cards --- */
.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(20px) saturate(160%);
    -webkit-backdrop-filter: blur(20px) saturate(160%);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius);
    padding: 1.5rem;
    margin-bottom: 1rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    animation: cardFadeIn 0.5s ease forwards;
    opacity: 0;
    transform: translateY(20px);
}

.glass-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.glass-card:hover {
    background: var(--glass-hover);
    border-color: rgba(255, 255, 255, 0.18);
    transform: translateY(-3px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.25);
}

.glass-card:hover::before {
    opacity: 1;
}

.glass-card:nth-child(1) { animation-delay: 0.05s; }
.glass-card:nth-child(2) { animation-delay: 0.1s; }
.glass-card:nth-child(3) { animation-delay: 0.15s; }
.glass-card:nth-child(4) { animation-delay: 0.2s; }
.glass-card:nth-child(5) { animation-delay: 0.25s; }
.glass-card:nth-child(6) { animation-delay: 0.3s; }

@keyframes cardFadeIn {
    to { opacity: 1; transform: translateY(0); }
}

/* --- Verse Display --- */
.verse-content {
    position: relative;
}

.verse-text {
    font-size: 1.25rem;
    line-height: 1.8;
    color: var(--text-primary);
    font-style: italic;
    font-weight: 500;
    margin-bottom: 1rem;
    padding: 1rem 1.5rem;
    border-left: 4px solid var(--primary);
    background: rgba(99, 102, 241, 0.06);
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

.verse-ref {
    text-align: right;
    color: var(--primary-light);
    font-weight: 700;
    font-size: 1rem;
    margin-top: -0.5rem;
}

/* --- Loading / Error States --- */
.loading {
    text-align: center;
    color: var(--text-muted);
    font-style: italic;
    padding: 2rem;
    animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 0.5; }
    50% { opacity: 1; }
}

.error {
    color: var(--danger);
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    padding: 1rem;
    border-radius: var(--radius-sm);
    text-align: center;
}

/* --- Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-decoration: none;
    white-space: nowrap;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(99, 102, 241, 0.45);
}

.btn-accent {
    background: linear-gradient(135deg, var(--accent), #d97706);
    color: #1a1a2e;
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.3);
}

.btn-accent:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(245, 158, 11, 0.45);
}

.btn-ghost {
    background: var(--glass-bg);
    color: var(--text-secondary);
    border: 1px solid var(--glass-border);
}

.btn-ghost:hover {
    background: var(--glass-hover);
    color: var(--text-primary);
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
}

/* --- Input Fields --- */
.input-field,
.form-input,
.form-textarea,
.form-select {
    width: 100%;
    padding: 0.85rem 1.1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 1rem;
    font-family: inherit;
    transition: all 0.3s ease;
    outline: none;
}

.input-field:focus,
.form-input:focus,
.form-textarea:focus,
.form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15);
    background: rgba(255, 255, 255, 0.08);
}

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

.form-select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23ffffff' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    padding-right: 2.5rem;
}

.form-select option {
    background: var(--bg-mid);
    color: var(--text-primary);
}

input[type="checkbox"] {
    accent-color: var(--primary);
    width: 1.1rem;
    height: 1.1rem;
    cursor: pointer;
}

/* --- Grid Layouts --- */
.grid-2 {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

.grid-3 {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

@media (min-width: 640px) {
    .grid-2 { grid-template-columns: repeat(2, 1fr); }
    .grid-3 { grid-template-columns: repeat(3, 1fr); }
}

@media (min-width: 1024px) {
    .grid-3 { grid-template-columns: repeat(3, 1fr); }
}

/* --- Tags / Badges --- */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.3rem 0.8rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge-primary { background: rgba(99, 102, 241, 0.2); color: var(--primary-light); }
.badge-accent { background: rgba(245, 158, 11, 0.2); color: var(--accent-light); }
.badge-success { background: rgba(16, 185, 129, 0.2); color: #6ee7b7; }
.badge-danger { background: rgba(239, 68, 68, 0.2); color: #fca5a5; }
.badge-urgent {
    background: linear-gradient(135deg, rgba(239,68,68,0.3), rgba(220,38,38,0.3));
    color: #fca5a5;
    border: 1px solid rgba(239,68,68,0.4);
    animation: badgePulse 2s ease-in-out infinite;
}

@keyframes badgePulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.3); }
    50% { box-shadow: 0 0 0 6px rgba(239, 68, 68, 0); }
}

/* --- About Section --- */
.about-text {
    color: var(--text-secondary);
    line-height: 1.8;
}

.about-text h3 {
    color: var(--text-primary);
    font-size: 1.2rem;
    margin: 1.5rem 0 0.5rem;
}

.about-text p {
    margin-bottom: 1rem;
}

/* --- Footer --- */
footer {
    text-align: center;
    padding: 2rem;
    color: var(--text-muted);
    font-size: 0.85rem;
    margin-top: 2rem;
    border-top: 1px solid var(--glass-border);
}

/* --- Scrollbar --- */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--bg-deep); }
::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.15); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,0.25); }

/* --- Utility --- */
.text-center { text-align: center; }
.text-accent { color: var(--accent-light); }
.text-muted { color: var(--text-muted); }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.flex-between { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 0.5rem; }
