@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600&family=Playfair+Display:ital,wght@0,400;0,600;0,700;1,400&family=Lora:ital,wght@0,400;0,500;1,400&display=swap');

:root {
    --bg-dark-900: #0a0a0a;
    --bg-dark-800: #121212;
    --bg-dark-700: #1a1a1a;
    --bg-dark-600: #242424;
    --gold-primary: #c5a880;
    --gold-light: #e0cca7;
    --gold-dark: #8c7352;
    --text-primary: #f0f0f0;
    --text-secondary: #a8a8a8;
    --text-muted: #6c757d;
    --font-serif: 'Playfair Display', Georgia, serif;
    --font-sans: 'Inter', system-ui, -apple-system, sans-serif;
    --font-body: 'Lora', Georgia, serif;
    --border-color: rgba(197, 168, 128, 0.15);
    --border-color-hover: rgba(197, 168, 128, 0.4);
    --transition-smooth: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Base Styles */
html, body {
    overflow-x: hidden;
}

body {
    background-color: var(--bg-dark-900);
    color: var(--text-primary);
    font-family: var(--font-body);
    font-size: 1.05rem;
    line-height: 1.7;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-serif);
    font-weight: 400;
    letter-spacing: 0.02em;
    color: var(--text-primary);
}

p {
    color: var(--text-secondary);
}

a {
    color: var(--gold-primary);
    text-decoration: none;
    transition: var(--transition-smooth);
}

a:hover {
    color: var(--gold-light);
    text-decoration: underline;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: var(--bg-dark-900);
}
::-webkit-scrollbar-thumb {
    background: var(--bg-dark-700);
    border-radius: 4px;
    border: 1px solid var(--border-color);
}
::-webkit-scrollbar-thumb:hover {
    background: var(--gold-dark);
}

/* Background/Hero Section */
.hero-section {
    position: relative;
    height: 75vh;
    min-height: 500px;
    width: 100%;
    background-color: var(--bg-dark-900);
    display: flex;
    align-items: flex-end;
    justify-content: center;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('andrei.jpg');
    background-size: cover;
    background-position: center 20%;
    background-repeat: no-repeat;
    z-index: 0;
}

@media (min-width: 769px) {
    .hero-section::before {
        left: 50%;
        transform: translateX(-50%);
        max-width: 600px;
        mask-image: linear-gradient(to right, transparent 0%, black 20%, black 80%, transparent 100%);
        -webkit-mask-image: linear-gradient(to right, transparent 0%, black 20%, black 80%, transparent 100%);
    }
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        to bottom,
        rgba(10, 10, 10, 0.4) 0%,
        rgba(10, 10, 10, 0.65) 50%,
        rgba(10, 10, 10, 0.95) 90%,
        var(--bg-dark-900) 100%
    );
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    text-align: center;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    text-shadow: 0 4px 12px rgba(0, 0, 0, 0.8);
    letter-spacing: 0.05em;
}

.hero-subtitle {
    font-family: var(--font-sans);
    font-size: 1.1rem;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--gold-primary);
    margin-bottom: 1.5rem;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.8);
}

.hero-dates {
    font-size: 1.25rem;
    font-family: var(--font-body);
    font-style: italic;
    color: var(--text-secondary);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.8);
}

/* Glassmorphism Cards */
.memorial-card {
    background-color: var(--bg-dark-800);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 2.5rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    transition: var(--transition-smooth);
    position: relative;
    overflow: hidden;
}

.memorial-card:hover {
    border-color: var(--border-color-hover);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.7);
}

/* Section Decorator */
.section-divider {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 3rem 0;
}

.section-divider::before,
.section-divider::after {
    content: '';
    height: 1px;
    width: 60px;
    background: linear-gradient(to right, transparent, var(--gold-primary));
}

.section-divider::after {
    background: linear-gradient(to left, transparent, var(--gold-primary));
}

.section-divider-icon {
    color: var(--gold-primary);
    margin: 0 1rem;
    font-size: 1.2rem;
}

/* Interactive Forms styling */
.form-label {
    font-family: var(--font-sans);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--gold-primary);
    font-weight: 500;
}

.form-control {
    background-color: var(--bg-dark-900) !important;
    border: 1px solid var(--border-color) !important;
    color: var(--text-primary) !important;
    padding: 0.8rem 1.2rem;
    border-radius: 6px;
    transition: var(--transition-smooth);
}

.form-control:focus {
    border-color: var(--gold-primary) !important;
    box-shadow: 0 0 0 3px rgba(197, 168, 128, 0.15) !important;
}

.form-check-input {
    background-color: var(--bg-dark-900);
    border: 1px solid var(--border-color);
}

.form-check-input:checked {
    background-color: var(--gold-primary);
    border-color: var(--gold-primary);
}

.form-check-input:focus {
    box-shadow: 0 0 0 3px rgba(197, 168, 128, 0.15);
}

/* Condolences List styling */
.condolence-item {
    border-left: 2px solid var(--gold-primary);
    background-color: var(--bg-dark-700);
    padding: 1.5rem 2rem;
    border-radius: 0 8px 8px 0;
    margin-bottom: 1.5rem;
    transition: var(--transition-smooth);
    border-top: 1px solid rgba(255, 255, 255, 0.02);
    border-right: 1px solid rgba(255, 255, 255, 0.02);
    border-bottom: 1px solid rgba(255, 255, 255, 0.02);
}

.condolence-item:hover {
    transform: translateX(4px);
    background-color: var(--bg-dark-600);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.condolence-meta {
    font-family: var(--font-sans);
    font-size: 0.85rem;
    color: var(--gold-primary);
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.condolence-author {
    font-weight: 600;
}

.condolence-date {
    color: var(--text-muted);
}

.condolence-text {
    font-size: 1rem;
    color: var(--text-primary);
    line-height: 1.6;
    margin: 0;
    font-style: italic;
}

/* Premium Buttons */
.btn-gold {
    background-color: transparent;
    border: 1px solid var(--gold-primary);
    color: var(--gold-primary);
    font-family: var(--font-sans);
    text-transform: uppercase;
    font-size: 0.9rem;
    font-weight: 500;
    letter-spacing: 0.1em;
    padding: 0.75rem 2rem;
    border-radius: 6px;
    transition: var(--transition-smooth);
}

.btn-gold:hover, .btn-gold:focus {
    background-color: var(--gold-primary);
    color: var(--bg-dark-900);
    box-shadow: 0 0 15px rgba(197, 168, 128, 0.3);
}

/* Respectful candle widget styling */
.candle-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 2rem 0;
}

.candle {
    width: 24px;
    height: 60px;
    background: linear-gradient(to bottom, #d4af37, #8c7352);
    border-radius: 4px 4px 2px 2px;
    position: relative;
    box-shadow: 0 0 10px rgba(197, 168, 128, 0.3);
}

.wick {
    width: 2px;
    height: 8px;
    background-color: #222;
    position: absolute;
    top: -8px;
    left: 11px;
}

.flame {
    width: 12px;
    height: 22px;
    background: radial-gradient(ellipse at bottom, #ff9600 0%, #ff5a00 50%, #ffdd00 100%);
    border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%;
    position: absolute;
    top: -28px;
    left: 6px;
    animation: flicker 1.5s infinite alternate;
    filter: drop-shadow(0 0 10px rgba(255, 150, 0, 0.6));
    transform-origin: center bottom;
}

@keyframes flicker {
    0% {
        transform: scale(0.9) rotate(-2deg);
        opacity: 0.9;
    }
    20% {
        transform: scale(1.05) rotate(1deg);
        opacity: 1;
    }
    40% {
        transform: scale(0.95) rotate(-1deg);
        opacity: 0.95;
    }
    60% {
        transform: scale(1.1) rotate(2deg);
        opacity: 1;
    }
    80% {
        transform: scale(1) rotate(-1deg);
        opacity: 0.9;
    }
    100% {
        transform: scale(1.05) rotate(0deg);
        opacity: 1;
    }
}

/* Quote styling */
.quote-text {
    font-size: 1.25rem;
    font-style: italic;
    color: var(--gold-primary);
    text-align: center;
    margin-bottom: 0.5rem;
}

.quote-author {
    font-family: var(--font-sans);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
    text-align: center;
}

/* Alert dynamic toast or message styling */
.custom-alert {
    background-color: var(--bg-dark-700);
    border: 1px solid var(--border-color);
    border-left: 3px solid var(--gold-primary);
    color: var(--text-primary);
    border-radius: 4px;
    padding: 1rem;
    margin-top: 1rem;
    display: none;
    font-family: var(--font-sans);
    font-size: 0.9rem;
}

/* Responsive Overrides */
@media (max-width: 768px) {
    .lang-selector {
        top: 15px;
        right: 15px;
        padding: 3px;
    }
    .lang-btn {
        padding: 4px 8px;
        font-size: 0.75rem;
    }
    .hero-title {
        font-size: 2.5rem;
    }
    .hero-section {
        height: 60vh;
    }
    .memorial-card {
        padding: 1.5rem;
    }
    .condolence-item {
        padding: 1.2rem;
    }
}

/* Language Selector styling */
.lang-selector {
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 100;
    display: flex;
    gap: 6px;
    background: rgba(10, 10, 10, 0.65);
    border: 1px solid var(--border-color);
    padding: 4px;
    border-radius: 30px;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
}

.lang-btn {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-family: var(--font-sans);
    font-size: 0.8rem;
    font-weight: 600;
    padding: 6px 12px;
    border-radius: 20px;
    transition: var(--transition-smooth);
    cursor: pointer;
    text-transform: uppercase;
}

.lang-btn:hover {
    color: var(--gold-light);
}

.lang-btn.active {
    background-color: var(--gold-primary);
    color: var(--bg-dark-900);
}
