/* Gratitude Journal Styles */
.gratitude-app {
    padding: 1rem;
    max-width: 1000px;
    margin: 0 auto;
    min-height: 70vh;
}

/* Category Selector */
.category-selector h2 {
    font-size: 2rem;
    color: #5a67d8;
    margin-bottom: 1.5rem;
    text-align: center;
}

.category-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.category-card {
    background: #f7fafc;
    padding: 1.5rem;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid #e2e8f0;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.category-card:hover {
    border-color: #667eea;
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(102, 126, 234, 0.15);
}

.category-card.active {
    border-color: #667eea;
    background: linear-gradient(135deg, #667eea15, #764ba215);
}

.category-icon {
    font-size: 2rem;
    margin-bottom: 1rem;
    display: inline-block;
}

.category-title {
    color: #2d3748;
    font-size: 1.2rem;
}

.category-desc {
    color: #718096;
    font-size: 1rem;
    line-height: 1.4;
    font-weight: 500;
    padding-top: 1rem;
}

.category-meta {
    padding: 0.25rem 0.75rem;
    border-radius: 5px;
    font-size: 0.9rem;
    background: #c6f6d5;
    color: #276749;
    font-weight: 600;
    margin-bottom: .75rem;
    margin-top: 1rem;
}

/* Question Interface */
.question-interface {
    background: #f8fafc;
    border-radius: 20px;
    padding: 2rem;
    margin: 1rem 0;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.progress-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #e2e8f0;
}

.progress-text {
    font-size: 1.1rem;
    font-weight: 600;
    color: #4a5568;
    background: #edf2f7;
    padding: 0.4rem 1rem;
    border-radius: 20px;
}

.category-name {
    font-size: 1rem;
    color: #667eea;
    font-weight: 600;
    background: white;
    padding: 0.4rem 1rem;
    border-radius: 20px;
    border: 1px solid #cbd5e0;
}

.question-card {
    padding: 1rem;
    margin-bottom: 1rem;
}

.question-card h3 {
    color: #2d3748;
    font-size: 1.4rem;
    line-height: 1.4;
    margin-bottom: 1.5rem;
    font-weight: 600;
}

#answerInput {
    width: 100%;
    padding: 1.25rem;
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    font-size: 1rem;
    font-family: inherit;
    resize: vertical;
    min-height: 150px;
    transition: all 0.3s ease;
    line-height: 1.5;
}

#answerInput:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

#answerInput::placeholder {
    color: #a0aec0;
    font-style: italic;
}

.answer-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #e2e8f0;
}

#charCount {
    font-size: 0.9rem;
    color: #718096;
    font-weight: 500;
}

.btn.skip {
    background: transparent;
    color: #718096;
    border: 1px solid #cbd5e0;
    padding: 0.3rem .6rem;
    font-size: 0.8rem;
}

.btn.skip:hover {
    background: #f7fafc;
    color: #4a5568;
}

.navigation-controls {
    display: flex;
    justify-content: space-between;
    margin-bottom: 2rem;
}

.export-section {
    text-align: center;
    margin: 2rem 0;
    padding: 2rem;
    background: linear-gradient(135deg, #f7fafc, #edf2f7);
    border-radius: 15px;
    border: 2px dashed #cbd5e0;
}

.btn.export {
    padding: 1rem 2rem;
    font-size: 1.1rem;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border: none;
    min-width: 300px;
}

.btn.export:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background: #a0aec0;
}

.btn.export:not(:disabled):hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.3);
}

.btn-icon {
    margin-right: 0.5rem;
    font-size: 1rem;
}

.export-note {
    color: #718096;
    font-size: 0.9rem;
    margin-top: 0.75rem;
    font-style: italic;
}

.back-link {
    background: none;
    border: none;
    color: #667eea;
    cursor: pointer;
    font-size: 1rem;
    padding: 0.5rem 1rem;
    margin-top: 1rem;
}

.back-link:hover {
    text-decoration: underline;
}

/* Review Interface */
.review-interface {
    max-width: 800px;
    margin: 0 auto;
    background: #f8fafc;
    border-radius: 20px;
    padding: 2rem;
}

.review-header {
    text-align: center;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 2px solid #e2e8f0;
}

.review-header h2 {
    color: #2d3748;
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.review-meta {
    display: flex;
    justify-content: center;
    gap: 2rem;
    color: #718096;
    font-weight: 500;
}

.answers-container {
    margin-bottom: 2rem;
}

.answer-review {
    background: white;
    padding: 1.5rem;
    border-radius: 12px;
    margin-bottom: 1.5rem;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
}

.answer-review h4 {
    color: #4a5568;
    font-size: 1.1rem;
    margin-bottom: 0.75rem;
    font-weight: 600;
}

.answer-content {
    color: #2d3748;
    line-height: 1.6;
    white-space: pre-wrap;
    padding: 1rem;
    background: #f7fafc;
    border-radius: 8px;
    font-size: 1rem;
}

.export-options {
    text-align: center;
    margin: 3rem 0;
    padding: 2rem;
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
}

.export-options h3 {
    color: #2d3748;
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
}

.export-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.review-actions {
    text-align: center;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 2px solid #e2e8f0;
}

/* Toast Notification */
.toast {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: #48bb78;
    color: white;
    padding: 1rem 1.5rem;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    z-index: 1000;
    animation: slideIn 0.3s ease;
    font-weight: 500;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Responsive Design */
@media (max-width: 768px) {

    .category-selector h2,
    .review-header h2 {
        font-size: 1.5rem;
    }

    .question-card {
        padding: .75rem;
    }

    .question-card h3 {
        font-size: 1.2rem;
    }

    .review-actions {
        flex-direction: column;
        gap: 1rem;
    }

    .review-meta {
        flex-direction: column;
        gap: 0.5rem;
    }

    .review-interface {
        padding: 1rem;
    }
}

@media (max-width: 480px) {

    .navigation-controls {
        flex-direction: column;
        gap: 1rem;
    }

    .progress-text {
        font-size: 0.8rem;
        padding: 0.2rem .7rem;
    }

    .category-name {
        font-size: 0.8rem;
        padding: 0.2rem .7rem;
    }

    .export-buttons {
        flex-direction: column;
    }

    .btn.export {
        padding: .5rem .5rem;
        font-size: 0.8rem;
        min-width: 150px;
    }

    .btn-icon {
        margin-right: 0.3rem;
        font-size: 1rem;
    }

    .question-card {
        padding: 0;
    }

    .question-interface {
        padding: 1rem;
    }
}

/* Tablet and larger */
@media (min-width: 600px) {
    .category-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Desktop and larger */
@media (min-width: 900px) {
    .category-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.btn {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 120px;
}

.btn.primary {
    background: #667eea;
    color: white;
}

.btn.primary:hover:not(:disabled) {
    background: #5a6fd8;
    transform: translateY(-1px);
}

.btn.secondary {
    background: #e2e8f0;
    color: #4a5568;
}

.btn.secondary:hover:not(:disabled) {
    background: #cbd5e0;
}

.btn.outline {
    background: transparent;
    color: #667eea;
    border: 2px solid #667eea;
}

.btn.outline:hover {
    background: #667eea;
    color: white;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none !important;
}

.back-to-categories {
    text-align: center;
}