@media (max-width: 480px) {
    .searchbar {
        width: 200px !important;
    }
}

/* --- Rich Content Styling --- */

/* Author Page */
.author-rich-content {
    background: #fff;
    padding: 20px;
    margin-bottom: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    font-family: 'Open Sans', sans-serif;
}

.bio-section {
    font-size: 1.1em;
    line-height: 1.6;
    color: #444;
    margin-bottom: 25px;
}

.timeline-section {
    background: #fdfdfd !important;
    /* Override inline */
    border-left: 4px solid #3498db;
    padding: 20px !important;
    margin-bottom: 25px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.timeline-section h4,
.trivia-section h4,
.faq-section h4 {
    margin-top: 0;
    color: #2c3e50;
    text-transform: uppercase;
    font-size: 0.9em;
    letter-spacing: 1px;
    border-bottom: 1px solid #eee;
    padding-bottom: 10px;
    margin-bottom: 15px;
}

.timeline-section ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.timeline-section ul li {
    position: relative;
    padding-left: 20px;
    margin-bottom: 10px;
    color: #555;
    border-left: 1px solid #ddd;
    margin-left: 5px;
}

.timeline-section ul li:before {
    content: '';
    position: absolute;
    left: -4px;
    top: 6px;
    width: 7px;
    height: 7px;
    background: #3498db;
    border-radius: 50%;
}

.trivia-section {
    background: #fff8e1 !important;
    /* Light yellow for trivia */
    border: none !important;
    border-left: 4px solid #f1c40f !important;
    padding: 20px !important;
}

.trivia-section ul li {
    margin-bottom: 8px;
}

/* Theme Page */
.catg_titile+div p {
    /* Definição Rich */
    font-size: 1.1em;
    line-height: 1.6;
    color: #333;
}

/* Phrase Page */
.frase-rich-analysis {
    background: #fafafa;
    padding: 25px;
    border-radius: 8px;
    border-top: 3px solid #e67e22;
    /* Accent color */
    margin-top: 30px;
}

.interpretation-box {
    font-family: 'Georgia', serif;
    font-size: 1.25em !important;
    color: #555;
    border-left: 3px solid #ccc;
    padding-left: 15px;
    margin-bottom: 25px !important;
}

.faq-section details {
    background: #fff !important;
    border: 1px solid #e0e0e0 !important;
    border-radius: 4px;
    margin-bottom: 10px;
    padding: 12px !important;
    transition: all 0.3s;
}

.faq-section details[open] {
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

/* Text-Only Phrase Cards */
.text-card-mode {
    text-align: left !important;
    border: 1px solid #ddd;
    border-radius: 6px;
    padding: 20px;
    margin-bottom: 25px;
    background: #fff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.03);
    overflow: hidden;
    /* Clear floats */
}

.text-card-mode .qt {
    font-size: 1.3em;
    line-height: 1.4;
    color: #444;
    font-family: 'Open Sans', sans-serif;
    display: block;
    margin-bottom: 10px;
}

.text-card-mode .btn {
    margin-top: 10px;
}

.text-card-mode .aut .autor {
    color: #666;
    font-size: 0.9em;
    font-weight: 600;
}

.text-card-mode .btn {
    display: inline-block;
    /* Changed from block to inline-block */
    margin-top: 10px;
}

.text-card-mode .aut .autor {
    font-weight: bold;
    color: #555;
    text-decoration: none;
    text-transform: uppercase;
    font-size: 0.9em;
}

/* Elegant Dropdown Menu */
.dropdown-menu-custom {
    position: absolute;
    top: 100%;
    /* Directly below the parent container */
    left: 0;
    /* Aligned with the left edge of the parent */
    width: 200px;
    /* Fixed width */
    background-color: #ffffff;
    border-radius: 8px;
    box-shadow: 0 5px 25px rgba(0, 0, 0, 0.15);
    padding: 5px 0;
    z-index: 99999;
    text-align: left;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

/* Little triangle arrow at top - moved to left */
.dropdown-menu-custom::before {
    content: "";
    position: absolute;
    top: -8px;
    left: 10px;
    /* Aligned with the hamburger center approximately */
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-bottom: 8px solid #ffffff;
}

/* Override overflow for containers to prevent clipping */
header.container,
nav.navbar,
.navbar-header,
.container {
    overflow: visible !important;
    content-visibility: visible !important;
    /* Fix for content-visibility: auto */
}

.dropdown-menu-custom ul li {
    display: block;
    width: 100%;
}

.dropdown-menu-custom ul li a {
    display: block;
    padding: 6px 15px;
    /* Reduced vertical padding */
    color: #555;
    text-decoration: none;
    font-size: 14px;
    /* Slightly smaller font if needed, or keep 15-16 */
    transition: background 0.2s, color 0.2s;
    border-bottom: 1px solid #f9f9f9;
}

.dropdown-menu-custom ul li:last-child a {
    border-bottom: none;
}

.dropdown-menu-custom ul li a:hover {
    background-color: #f9f9f9;
    color: #ce1c00;
    /* Theme red color */
    padding-left: 25px;
    /* Subtle movement effect */
}

.dropdown-menu-custom ul li a i {
    width: 25px;
    /* Fixed width for icons alignment */
    color: #999;
    margin-right: 5px;
}

.dropdown-menu-custom ul li a:hover i {
    color: #ce1c00;
}

/* Positioning adjustments for mobile */
@media (max-width: 767px) {
    .dropdown-menu-custom {
        right: 10px;
        left: 10px;
        /* Full width minus margins on very small screens? Or just floated right */
        width: auto;
    }
}