body {
    margin: 0;
    font-family: Arial, sans-serif;
    color: #333;
    background: linear-gradient(to bottom, #cce7ff, #e0f7fa); /* Soft blue to light blue gradient */
}

.quote-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    text-align: center;
    padding: 20px;
}

.quote-overlay {
    background: rgba(255, 255, 255, 0.8);
    border-radius: 10px;
    padding: 20px;
    max-width: 90%; /* Adjusted for better mobile fit */
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    margin-bottom: 40px; /* Space between quote box and button */
}

.quote-text {
    font-size: 1.2em; /* Adjusted for smaller screens */
    font-family: 'Dancing Script', cursive; /* Google Font */
    line-height: 1.6;
    white-space: pre-wrap; /* Preserve whitespace for typewriter effect */
    overflow: hidden; /* Hide overflow text during animation */
}

.quote-author {
    display: block;
    margin-top: 10px;
    font-size: 0.9em; /* Slightly smaller for mobile */
    font-style: italic;
}

.back-button {
    background: rgba(255, 255, 255, 0.8);
    color: black;
    border: 1px solid black;
    border-radius: 5px;
    padding: 10px 20px;
    cursor: pointer;
    font-size: 1em;
    transition: background 0.3s;
}

.back-button:hover {
    background: rgba(255, 255, 255, 1);
}

/* Additional mobile-specific styling */
@media (max-width: 768px) {
    .quote-text {
        font-size: 1.1em; /* Further adjust font size for smaller screens */
    }

    .quote-overlay {
        padding: 15px; /* Reduce padding for mobile */
    }

    .back-button {
        font-size: 0.9em; /* Slightly smaller button text on mobile */
        padding: 8px 16px; /* Reduce button padding on mobile */
    }
}
