/* The Lamp Post - Elegant CSS Styling */

/* CSS Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #1e2839;
    background: linear-gradient(135deg, #f0f2f7 0%, #e1e5ed 100%);
    min-height: 100vh;
}

/* Typography */
h1, h2, h3 {
    font-weight: 600;
    line-height: 1.3;
}

/* Container and Layout */
.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 20px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Header Styles */
.header {
    background: linear-gradient(135deg, #1a2b4a 0%, #0f1a2e 100%);
    color: white;
    padding: 2.5rem 0;
    margin: 0 -20px 2rem;
    text-align: center;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(15, 26, 46, 0.3);
}

.header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="25" cy="25" r="0.5" fill="white" opacity="0.1"/><circle cx="75" cy="75" r="0.3" fill="white" opacity="0.08"/><circle cx="50" cy="10" r="0.4" fill="white" opacity="0.06"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>') repeat;
    pointer-events: none;
}

.header-content {
    position: relative;
    z-index: 1;
}

.logo-image {
    width: 120px;
    height: 120px;
    margin-bottom: 1rem;
    filter: drop-shadow(0 4px 8px rgba(0,0,0,0.3));
}

.tagline {
    font-size: 1.2rem;
    opacity: 0.95;
    font-weight: 300;
    font-style: italic;
    font-family: 'Crimson Text', Georgia, serif;
    color: #f4d03f;
    margin-bottom: 0.25rem;
}

.tagline-reference {
    font-size: 0.95rem;
    opacity: 0.8;
    font-weight: 400;
    color: #d4af37;
}

/* Main Content */
.main-content {
    flex: 1;
    padding-bottom: 2rem;
}

/* Light from the Word Q&A Section */
.light-qa-section {
    margin-bottom: 2.5rem;
    animation: fadeInUp 0.8s ease-out;
}

.light-qa-container {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, rgba(252, 249, 240, 0.98) 100%);
    border-radius: 20px;
    padding: 2.5rem;
    box-shadow: 0 10px 40px rgba(26, 43, 74, 0.12);
    border: 1px solid rgba(212, 175, 55, 0.15);
    position: relative;
}

.light-qa-header {
    display: flex;
    gap: 2.5rem;
    align-items: flex-start;
    margin-bottom: 2rem;
}

.light-qa-logo {
    flex-shrink: 0;
}

.qa-logo-image {
    width: 100px;
    height: 100px;
    border-radius: 16px;
    box-shadow: 0 6px 20px rgba(26, 43, 74, 0.15);
    border: 2px solid rgba(212, 175, 55, 0.25);
    background: white;
    padding: 8px;
}

.light-qa-intro {
    flex: 1;
}

.light-qa-title {
    font-family: 'Crimson Text', Georgia, serif;
    font-size: 2rem;
    font-weight: 600;
    color: #1a2b4a;
    margin: 0 0 0.25rem 0;
}

.light-qa-subtitle {
    font-size: 1rem;
    color: #4a5a75;
    margin: 0 0 1.25rem 0;
}

.light-qa-form {
    margin-bottom: 1rem;
}

.light-qa-input-group {
    display: flex;
    gap: 0.5rem;
}

#light-question-input {
    flex: 1;
    padding: 0.75rem 1rem;
    font-size: 1rem;
    border: 2px solid #e0e5eb;
    border-radius: 10px;
    background: white;
    transition: all 0.3s ease;
}

#light-question-input:focus {
    outline: none;
    border-color: #d4af37;
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.1);
}

.light-qa-submit {
    padding: 0.75rem 1.5rem;
    background: linear-gradient(135deg, #d4af37 0%, #f4d03f 100%);
    color: #1a2b4a;
    border: none;
    border-radius: 10px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 3px 10px rgba(212, 175, 55, 0.3);
}

.light-qa-submit:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(212, 175, 55, 0.4);
}

.light-qa-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.light-chip {
    padding: 0.4rem 0.9rem;
    font-size: 0.85rem;
    color: #1a2b4a;
    background: rgba(212, 175, 55, 0.1);
    border: 1px solid rgba(212, 175, 55, 0.25);
    border-radius: 16px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.light-chip:hover {
    background: rgba(212, 175, 55, 0.2);
    border-color: #d4af37;
}

/* Scripture Cards in Light Q&A */
.light-qa-results {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(212, 175, 55, 0.15);
}

.light-scripture-cards {
    display: grid;
    gap: 1.25rem;
}

.light-scripture-card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 4px 15px rgba(26, 43, 74, 0.08);
    border: 1px solid rgba(212, 175, 55, 0.1);
    transition: all 0.3s ease;
}

.light-scripture-card:hover {
    box-shadow: 0 6px 20px rgba(26, 43, 74, 0.12);
    transform: translateY(-2px);
}

.light-verse-reference {
    display: block;
    font-family: 'Crimson Text', Georgia, serif;
    font-size: 1.1rem;
    font-weight: 600;
    color: #d4af37;
    margin-bottom: 0.75rem;
}

.light-verse-text {
    font-family: 'Crimson Text', Georgia, serif;
    font-size: 1.15rem;
    line-height: 1.7;
    color: #1a2b4a;
    font-style: italic;
    margin: 0 0 1rem 0;
    padding-left: 1rem;
    border-left: 3px solid rgba(212, 175, 55, 0.3);
}

.light-verse-note {
    font-size: 0.95rem;
    color: #4a5a75;
    font-style: italic;
    margin: 0;
}

/* Loading State */
.light-qa-loading {
    text-align: center;
    padding: 2rem;
}

.light-loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(212, 175, 55, 0.2);
    border-top-color: #d4af37;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1rem;
}

/* Daily Light Section */
.daily-light-section {
    margin-bottom: 2.5rem;
    animation: fadeInUp 0.8s ease-out;
}

.daily-light-container {
    background: linear-gradient(135deg, #fff 0%, #fefbf3 100%);
    border-radius: 20px;
    padding: 2rem;
    box-shadow: 0 8px 30px rgba(212, 175, 55, 0.15);
    border: 2px solid rgba(212, 175, 55, 0.2);
    position: relative;
    overflow: hidden;
}

.daily-light-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, #d4af37 0%, #f4d03f 50%, #d4af37 100%);
}

.daily-light-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.daily-light-badge {
    background: linear-gradient(135deg, #d4af37 0%, #f4d03f 100%);
    color: #1a2b4a;
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(212, 175, 55, 0.3);
}

.daily-light-date {
    color: #4a5a75;
    font-size: 0.95rem;
    font-weight: 500;
}

.daily-verse-card {
    text-align: center;
}

.daily-verse-text {
    font-family: 'Crimson Text', Georgia, serif;
    font-size: 1.5rem;
    line-height: 1.8;
    color: #1a2b4a;
    margin: 0 auto 1.25rem;
    font-style: italic;
    max-width: 90%;
    position: relative;
}

.daily-verse-text::before {
    content: '✨';
    position: absolute;
    left: -2rem;
    top: 0;
    font-size: 1.5rem;
}

.daily-verse-text::after {
    content: '✨';
    position: absolute;
    right: -2rem;
    bottom: 0;
    font-size: 1.5rem;
}

.daily-verse-reference {
    display: block;
    font-family: 'Inter', sans-serif;
    font-size: 1.1rem;
    font-weight: 600;
    color: #d4af37;
    font-style: normal;
    margin-bottom: 1rem;
}

.daily-verse-interpretation {
    margin: 1.5rem auto;
    padding: 1rem;
    background: rgba(212, 175, 55, 0.05);
    border-radius: 12px;
    max-width: 85%;
}

.daily-interpretation-text {
    font-family: 'Inter', sans-serif;
    font-size: 1.05rem;
    line-height: 1.6;
    color: #4a5a75;
    margin: 0;
}

.daily-verse-reflection {
    margin-top: 1.75rem;
    padding-top: 1.5rem;
    border-top: 2px dotted rgba(212, 175, 55, 0.3);
}

.reflection-label {
    font-size: 0.9rem;
    font-weight: 600;
    color: #1a2b4a;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 0.75rem;
    opacity: 0.8;
}

.reflection-text {
    font-family: 'Inter', sans-serif;
    font-size: 1.05rem;
    line-height: 1.7;
    color: #2c3e50;
    font-style: italic;
    max-width: 85%;
    margin: 0 auto;
}

/* Input Section */
.input-section {
    margin-bottom: 3rem;
}

.input-container {
    background: white;
    border-radius: 16px;
    padding: 2.5rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.8);
}

.section-title {
    font-size: 1.75rem;
    color: #1a2b4a;
    margin-bottom: 0.75rem;
    text-align: center;
}

.section-subtitle {
    color: #64748b;
    text-align: center;
    margin-bottom: 2rem;
    font-size: 1.05rem;
}

/* Form Styles */
.verse-form {
    max-width: 100%;
}

.form-group {
    margin-bottom: 1.5rem;
}

textarea {
    width: 100%;
    padding: 1rem;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    font-family: inherit;
    font-size: 1rem;
    resize: vertical;
    min-height: 120px;
    max-height: 200px;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    background: #fafbfc;
}

textarea:focus {
    outline: none;
    border-color: #d4af37;
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.15);
    background: white;
}

textarea::placeholder {
    color: #94a3b8;
    font-style: italic;
}

/* Button Styles */
.submit-btn {
    width: 100%;
    padding: 1rem 2rem;
    background: linear-gradient(135deg, #d4af37 0%, #f4d03f 100%);
    color: #1a2b4a;
    border: none;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.submit-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(212, 175, 55, 0.4);
    background: linear-gradient(135deg, #f4d03f 0%, #ffd700 100%);
}

.submit-btn:active {
    transform: translateY(0);
}

.submit-btn:disabled {
    cursor: not-allowed;
    opacity: 0.7;
}

.btn-loading {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-loading::before {
    content: '';
    width: 16px;
    height: 16px;
    border: 2px solid transparent;
    border-top: 2px solid currentColor;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.secondary-btn {
    padding: 0.75rem 1.5rem;
    background: transparent;
    color: #1a2b4a;
    border: 2px solid #1a2b4a;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.secondary-btn:hover {
    background: #1a2b4a;
    color: white;
    transform: translateY(-1px);
}

/* Results Section */
.results-section {
    animation: fadeInUp 0.6s ease-out;
}

/* Pastoral Note */
.pastoral-note {
    background: linear-gradient(135deg, #fef9e5 0%, #fff8dc 100%);
    border: 1px solid #d4af37;
    border-radius: 16px;
    padding: 1.5rem;
    margin-bottom: 2rem;
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    box-shadow: 0 2px 10px rgba(212, 175, 55, 0.15);
}

.pastoral-note-icon {
    font-size: 1.5rem;
    flex-shrink: 0;
}

.pastoral-note-content {
    flex: 1;
}

.pastoral-note-title {
    color: #1a2b4a;
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.pastoral-note-text {
    color: #4a5a75;
    font-style: italic;
    line-height: 1.6;
}

/* Verse Cards */
.verses-container {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.verse-card {
    background: white;
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.8);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    overflow: hidden;
}

.verse-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(135deg, #d4af37 0%, #f4d03f 100%);
}

.verse-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.verse-content {
    position: relative;
    z-index: 1;
}

.verse-text {
    font-family: 'Crimson Text', Georgia, serif;
    font-size: 1.25rem;
    line-height: 1.7;
    color: #1a2b4a;
    margin-bottom: 1rem;
    font-style: italic;
    position: relative;
    padding-left: 1rem;
}

.verse-text::before {
    content: '"';
    position: absolute;
    left: -0.25rem;
    top: -0.1rem;
    font-size: 3rem;
    color: #d4af37;
    font-family: Georgia, serif;
    line-height: 1;
}

.verse-reference {
    display: block;
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    font-weight: 600;
    color: #d4af37;
    font-style: normal;
    text-align: right;
    margin-top: 1rem;
}

.verse-interpretation {
    margin-top: 1.25rem;
    padding-top: 1.25rem;
    border-top: 1px solid #e5e7eb;
}

.interpretation-label {
    font-size: 0.85rem;
    font-weight: 600;
    color: #1a2b4a;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.5rem;
    opacity: 0.7;
}

.interpretation-text {
    font-family: 'Inter', sans-serif;
    font-size: 1.05rem;
    line-height: 1.6;
    color: #4a5a75;
    font-style: normal;
}

.verse-source {
    font-size: 0.85rem;
    color: #64748b;
    text-align: right;
    margin-top: 0.75rem;
    opacity: 0.8;
}

/* Actions */
.actions-container {
    text-align: center;
}

/* Loading Section */
.loading-section {
    text-align: center;
    padding: 3rem 0;
}

.loading-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid #e2e8f0;
    border-top: 3px solid #d4af37;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.loading-text {
    color: #64748b;
    font-size: 1.1rem;
    font-style: italic;
}

/* Error Section */
.error-section {
    text-align: center;
    padding: 2rem 0;
}

.error-container {
    background: white;
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    max-width: 500px;
    margin: 0 auto;
}

.error-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.error-title {
    color: #dc2626;
    margin-bottom: 0.75rem;
    font-size: 1.25rem;
}

.error-message {
    color: #64748b;
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

/* Footer */
.footer {
    margin-top: auto;
    padding: 2rem 0 1rem;
    text-align: center;
    border-top: 1px solid #e2e8f0;
    margin-left: -20px;
    margin-right: -20px;
    padding-left: 20px;
    padding-right: 20px;
}

.footer-content {
    max-width: 600px;
    margin: 0 auto;
}

.footer-text {
    color: #64748b;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.footer-verse {
    color: #94a3b8;
    font-size: 0.85rem;
    font-style: italic;
    font-family: 'Crimson Text', Georgia, serif;
}

/* Utility Classes */
.hidden {
    display: none !important;
}

/* Animations */
@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .light-qa-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 1.5rem;
    }
    
    .qa-logo-image {
        width: 80px;
        height: 80px;
    }
    
    .light-qa-title {
        font-size: 1.6rem;
    }
    
    .light-qa-input-group {
        flex-direction: column;
    }
    
    .light-qa-submit {
        width: 100%;
    }
    
    .daily-light-container {
        padding: 1.5rem;
    }
    
    .daily-verse-text {
        font-size: 1.25rem;
    }
    
    .daily-verse-text::before,
    .daily-verse-text::after {
        display: none;
    }
    
    .daily-interpretation-text,
    .reflection-text {
        font-size: 0.95rem;
    }
    .container {
        padding: 0 16px;
    }
    
    .header {
        margin: 0 -16px 1.5rem;
        padding: 2rem 0;
    }
    
    .logo-image {
        width: 100px;
        height: 100px;
    }
    
    .tagline {
        font-size: 1rem;
    }
    
    .input-container {
        padding: 1.5rem;
        border-radius: 12px;
    }
    
    .section-title {
        font-size: 1.5rem;
    }
    
    .verse-card {
        padding: 1.5rem;
        border-radius: 12px;
    }
    
    .verse-text {
        font-size: 1.1rem;
    }
    
    .interpretation-text {
        font-size: 0.95rem;
    }
    
    .pastoral-note {
        padding: 1rem;
        border-radius: 12px;
        flex-direction: column;
        text-align: center;
    }
    
    .footer {
        margin-left: -16px;
        margin-right: -16px;
        padding-left: 16px;
        padding-right: 16px;
    }
}

@media (max-width: 480px) {
    .light-qa-container {
        padding: 1.5rem;
    }
    
    .qa-logo-image {
        width: 70px;
        height: 70px;
        padding: 6px;
    }
    
    .light-qa-title {
        font-size: 1.4rem;
    }
    
    .light-qa-subtitle {
        font-size: 0.9rem;
    }
    
    #light-question-input {
        font-size: 0.95rem;
    }
    
    .light-chip {
        font-size: 0.8rem;
        padding: 0.35rem 0.7rem;
    }
    
    .daily-light-container {
        padding: 1rem;
        border-radius: 12px;
    }
    
    .daily-light-header {
        flex-direction: column;
        gap: 0.5rem;
        text-align: center;
    }
    
    .daily-verse-text {
        font-size: 1.1rem;
    }
    
    .daily-interpretation-text,
    .reflection-text {
        font-size: 0.9rem;
    }
    .logo-image {
        width: 80px;
        height: 80px;
    }
    
    .section-title {
        font-size: 1.3rem;
    }
    
    .input-container {
        padding: 1rem;
    }
    
    .verse-card {
        padding: 1rem;
    }
    
    .verse-text {
        font-size: 1rem;
        line-height: 1.6;
    }
    
    .interpretation-text {
        font-size: 0.9rem;
    }
}

/* Print Styles */
@media print {
    .header,
    .input-section,
    .actions-container,
    .footer {
        display: none;
    }
    
    .verse-card {
        break-inside: avoid;
        box-shadow: none;
        border: 1px solid #ccc;
        margin-bottom: 1rem;
    }
    
    .verse-text {
        color: #000;
    }
    
    .verse-reference {
        color: #333;
    }
}