body, .bismillah-text, .logo, .bio-text p, .couplet-line, .page-info, .bio-toggle-btn, .search-box input, .search-box button, .music-status, .volume-value {
    font-family: 'Tahoma', 'Segoe UI', 'Arial', 'Scheherazade New', 'Amiri', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

.poem {
    direction: rtl;
    text-align: center; 
    margin: 0 auto;       
    width: 60%; 
    line-height: 2.2;
}

.line {
    text-align: justify;     
    text-align-last: justify; 
    width: 100%;
    display: inline-block;
}

.line::after {
    content: "";
    display: inline-block;
    width: 100%; 
}

body {
    background: #f5efe9;
    min-height: 100vh;
    color: #3a2c1f;
    width: 100%;
    overflow-x: hidden;
}

body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="100" height="100" viewBox="0 0 100 100"><filter id="noise"><feTurbulence type="fractalNoise" baseFrequency="0.65" numOctaves="1" stitchTiles="stitch"/></filter><rect width="100" height="100" filter="url(%23noise)" opacity="0.1"/></svg>');
    pointer-events: none;
    z-index: 9999;
    opacity: 0.15;
}

/* ========== FIXED NAVBAR ========== */
.header {
    background: #3e2c1b;
    padding: 0.8rem 2rem;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 4px 20px rgba(0,0,0,0.25);
    border-bottom: 2px solid #e4b381;
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    direction: ltr;
}

.nav-left {
    flex-shrink: 0;
}

.nav-right {
    flex-shrink: 0;
}

.logo {
    font-size: 2rem;
    font-weight: bold;
    text-decoration: none;
    color: #f5e6d3;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
    white-space: nowrap;
    transition: all 0.3s ease;
    direction: rtl;
    display: inline-block;
}

.logo:hover {
    transform: scale(1.02);
    color: #e4b381;
}

.logo span {
    color: #e4b381;
    font-style: italic;
}

/* Music Control */
.music-control {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(8px);
    padding: 0.4rem 1.2rem;
    border-radius: 50px;
    border: 1px solid rgba(228, 179, 129, 0.3);
    flex-shrink: 0;
    transition: all 0.3s ease;
    direction: rtl;
}

.music-control:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(228, 179, 129, 0.5);
}

.music-btn, .upload-btn, .reset-btn {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    transition: all 0.3s ease;
    border: none;
}

.music-btn {
    background: linear-gradient(135deg, #8b6f50, #6b4f32);
    color: #f5e6d3;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

.music-btn:hover {
    transform: scale(1.1);
    background: linear-gradient(135deg, #9b7f60, #7b5f42);
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

.upload-btn {
    background: rgba(184, 155, 123, 0.8);
    color: #3e2c1b;
}

.upload-btn:hover {
    background: #b89b7b;
    transform: scale(1.1);
}

.reset-btn {
    background: rgba(107, 79, 50, 0.8);
    color: #f5e6d3;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
}

.reset-btn:hover {
    background: #6b4f32;
    transform: scale(1.1);
}

.music-status {
    color: #f5e6d3;
    font-size: 0.85rem;
    white-space: nowrap;
    font-weight: 500;
}

#musicUpload {
    display: none;
}

/* Volume Control */
.volume-control {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(0, 0, 0, 0.3);
    padding: 0.3rem 0.8rem;
    border-radius: 30px;
    margin-right: 0.3rem;
}

.volume-btn {
    background: none;
    border: none;
    color: #f5e6d3;
    cursor: pointer;
    font-size: 0.9rem;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.volume-btn:hover {
    background: rgba(255,255,255,0.1);
    transform: scale(1.1);
}

.volume-slider {
    width: 90px;
    height: 4px;
    background: rgba(228, 179, 129, 0.5);
    border-radius: 2px;
    cursor: pointer;
}

.volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 14px;
    height: 14px;
    background: #e4b381;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 0 4px rgba(0,0,0,0.3);
    transition: all 0.2s;
}

.volume-slider::-webkit-slider-thumb:hover {
    transform: scale(1.2);
    background: #f5e6d3;
}

.volume-value {
    color: #f5e6d3;
    font-size: 0.75rem;
    min-width: 38px;
    font-weight: 500;
}

/* Music Message */
.music-message {
    position: fixed;
    top: 90px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #faf3e8, #f5e6d3);
    border: 2px solid #e4b381;
    padding: 0.8rem 2rem;
    border-radius: 50px;
    color: #3e2c1b;
    font-size: 0.95rem;
    z-index: 2000;
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    animation: slideDown 0.4s ease;
    backdrop-filter: blur(10px);
}

@keyframes slideDown {
    from { top: 60px; opacity: 0; transform: translateX(-50%) scale(0.9); }
    to { top: 90px; opacity: 1; transform: translateX(-50%) scale(1); }
}

/* Main content spacing */
.main-content {
    margin-top: 85px;
    padding: 0 2rem;
    max-width: 100%;
    overflow-x: hidden;
}

/* ========== IMPROVED SEARCH STYLES ========== */
.search-container {
    max-width: 700px;
    margin: 2rem auto;
    position: relative;
}

.search-wrapper {
    width: 100%;
}

.search-box {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: white;
    border: 3px solid #b89b7b;
    border-radius: 60px;
    padding: 0.3rem 0.3rem 0.3rem 1rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

.search-box:focus-within {
    border-color: #e4b381;
    box-shadow: 0 4px 20px rgba(228, 179, 129, 0.2);
    transform: translateY(-2px);
}

.search-icon {
    color: #b89b7b;
    font-size: 1.1rem;
}

.search-box input {
    flex: 1;
    padding: 0.9rem 0;
    border: none;
    background: transparent;
    font-size: 1rem;
    direction: rtl;
    outline: none;
}

.search-box input::placeholder {
    color: #c9af91;
}

.clear-btn {
    background: #e8d9cc;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    color: #8b6f50;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.clear-btn:hover {
    background: #d4b99b;
    color: #3e2c1b;
    transform: scale(1.05);
}

.search-info {
    text-align: center;
    margin: 1rem auto;
    padding: 0.8rem 1.5rem;
    background: #faf3e8;
    border: 2px solid #b89b7b;
    border-radius: 40px;
    max-width: 500px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.8rem;
    flex-wrap: wrap;
    font-size: 0.9rem;
    color: #6b4f32;
}

.search-info i {
    color: #b89b7b;
}

.search-info strong {
    color: #8b6f50;
    font-weight: bold;
}

/* ========== IMPROVED POEM CARD STYLES ========== */
.poems-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1.8rem;
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0.5rem;
    align-items: start;
    justify-content: center;
}

.poem-card {
    background: #fffef8;
    border-radius: 24px;
    box-shadow: 0 10px 25px -5px rgba(0,0,0,0.1), 0 8px 10px -6px rgba(0,0,0,0.02);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    border: 1px solid #e8d9cc;
    overflow: hidden;
    position: relative;
    width: 100%;
    max-width: 100%;
}

.poem-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 30px -12px rgba(0,0,0,0.2);
    border-color: #d4b99b;
    background: #fffdf9;
}

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

.poem-content {
    flex: 1;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding: 1.5rem 1rem 1rem;
    text-align: right;
    overflow: hidden;
    min-height: 0;
}

.poem-lines-wrapper {
    margin: 0 auto;
    width: 100%;
    max-height: 380px;
    overflow-y: auto;
    padding: 0.25rem 0.5rem;
    scrollbar-width: thin;
    word-wrap: break-word;
    overflow-wrap: break-word;
    word-break: break-word;
    display: flex;
    flex-direction: column;
    text-align: center !important;
    direction: rtl;
    font-family: 'Noto Nastaliq Urdu', 'Amiri', 'Tahoma', monospace;
    font-size: 1rem;
    line-height: 2;
    color: #2c241a;
    white-space: normal;
}

.poem-lines-wrapper::-webkit-scrollbar {
    width: 4px;
}

.poem-lines-wrapper::-webkit-scrollbar-track {
    background: #f0e6dc;
    border-radius: 4px;
}

.poem-lines-wrapper::-webkit-scrollbar-thumb {
    background: #c9af91;
    border-radius: 4px;
}

/* Audio player styling */
.poem-audio {
    width: calc(100% - 2rem);
    margin: 0.5rem auto 0.2rem;
    height: 40px;
    border-radius: 30px;
    background: #f5efe9;
}

.poem-audio:focus {
    outline: none;
}

.poem-audio-playing {
    background: linear-gradient(145deg, #fffef8, #fef7ef);
    border: 1px solid #e4b381 !important;
    box-shadow: 0 0 0 2px rgba(228, 179, 129, 0.3);
}

.card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 1.25rem;
    background: #faf6f0;
    border-top: 1px solid #eadbcb;
    margin-top: 0.5rem;
    flex-wrap: wrap;
    gap: 0.5rem;
    min-height: 55px;
    direction: rtl;
}

.page-badge {
    background: #8b6f50;
    color: #fdf6ed;
    padding: 0.3rem 0.9rem;
    border-radius: 40px;
    font-size: 0.75rem;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-weight: 500;
    letter-spacing: 0.5px;
}

.views {
    color: #8b7355;
    font-size: 0.75rem;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: rgba(139, 111, 80, 0.1);
    padding: 0.2rem 0.8rem;
    border-radius: 30px;
}

.poet-signature {
    color: #b89b7b;
    font-size: 0.7rem;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: rgba(184, 155, 123, 0.15);
    padding: 0.2rem 0.8rem;
    border-radius: 30px;
    font-style: italic;
}

/* ========== FIXED SEARCH HIGHLIGHT - NO SIZE CHANGE, NO ALIGNMENT BREAK ========== */
.search-highlight {
    background-color: #ffeb3b;
    color: #3e2c1b;
    padding: 0 2px;
    border-radius: 3px;
    font-weight: normal;
    font-size: inherit;
    font-family: inherit;
    line-height: inherit;
    display: inline;
    white-space: normal;
    word-break: break-word;
}

/* ========== OTHER STYLES ========== */
.bio-toggle-btn {
    background: #b89b7b;
    color: #3e2c1b;
    padding: 0.5rem 1.5rem;
    border: 2px solid #e4b381;
    cursor: pointer;
    font-size: 1.2rem;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 0.8rem;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    margin: 1rem auto;
    text-decoration: none;
    border-radius: 50px;
}

.bio-toggle-btn:hover {
    background: #e4b381;
    transform: translateY(-3px);
}

.biography-section {
    width: 100%;
    max-width: 900px;
    margin: 2rem auto;
    background: #fcf8f0;
    border: 10px double #b89b7b;
    padding: 2rem;
    position: relative;
    box-shadow: 15px 15px 30px rgba(0,0,0,0.2);
    animation: bioFadeIn 0.8s ease;
    overflow-x: hidden;
    border-radius: 20px;
}

@keyframes bioFadeIn {
    from { opacity: 0; transform: translateY(-30px); }
    to { opacity: 1; transform: translateY(0); }
}

.biography-section::before {
    content: "❀";
    position: absolute;
    top: -20px;
    left: 20px;
    background: #fcf8f0;
    color: #b89b7b;
    font-size: 40px;
    padding: 0 20px;
    transform: rotate(-15deg);
    z-index: 10;
}

.biography-section::after {
    content: "❀";
    position: absolute;
    top: -20px;
    right: 20px;
    background: #fcf8f0;
    color: #b89b7b;
    font-size: 40px;
    padding: 0 20px;
    transform: rotate(15deg);
    z-index: 10;
}

.about-section {
    text-align: center;
    padding: 2rem 1rem;
    background: #faf3e8;
    border: 8px double #b89b7b;
    margin-bottom: 1rem;
    width: 100%;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    box-shadow: 10px 10px 20px rgba(0,0,0,0.1);
    position: relative;
    border-radius: 20px;
}

.about-section::before {
    content: "❀";
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%);
    background: #faf3e8;
    color: #b89b7b;
    font-size: 30px;
    padding: 0 25px;
    white-space: nowrap;
    z-index: 2;
}

.about-section h1 {
    font-size: 2rem;
    margin: 0.5rem 0;
    color: #3e2c1b;
    text-shadow: 2px 2px 0 #e4b381;
}

.couplet-line {
    font-size: 1.2rem;
    line-height: 2;
    margin: 0.3rem 0;
    padding: 0.3rem 1rem;
    background: rgba(255, 255, 255, 0.5);
    border-right: 4px solid #e4b381;
    text-align: center;
    color: #3e2c1f;
}

.logo-image-section, .poet-image-section {
    width: 100%;
    max-width: 800px;
    margin: 1rem auto;
    text-align: center;
}

.logo-image, .poet-image {
    width: 100%;
    height: auto;
    max-height: 400px;
    object-fit: contain;
}

.poet-image-container {
    background: #faf3e8;
    border: 8px double #b89b7b;
    padding: 1.5rem;
    position: relative;
    border-radius: 20px;
}

.bismillah-container {
    max-width: 800px;
    margin: 1.5rem auto;
    text-align: center;
    padding: 1rem;
    background: linear-gradient(135deg, #faf3e8, #f5e6d3);
    border: 3px solid #b89b7b;
    border-radius: 60px;
}

.bismillah-text {
    font-size: 2rem;
    color: #3e2c1b;
}

.pagination-container {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 2rem 0;
    flex-wrap: wrap;
    gap: 0.8rem;
}

.pagination {
    display: flex;
    gap: 0.3rem;
    flex-wrap: wrap;
}

.page-link {
    padding: 0.5rem 0.9rem;
    background: #f5e6d3;
    border: 2px solid #b89b7b;
    border-radius: 8px;
    color: #3e2c1b;
    text-decoration: none;
    min-width: 40px;
    text-align: center;
    transition: all 0.2s;
}

.page-link:hover {
    background: #e4d5c0;
}

.page-link.active {
    background: #8b6f50;
    color: #f5e6d3;
    border-color: #6b4f32;
}

.page-nav-large {
    padding: 0.5rem 1.2rem;
    background: #8b6f50;
    color: #f5e6d3;
    text-decoration: none;
    border-radius: 8px;
    border: 2px solid #6b4f32;
    white-space: nowrap;
    transition: all 0.2s;
}

.page-nav-large:hover {
    background: #6b4f32;
}

.page-nav-large.disabled {
    opacity: 0.4;
    pointer-events: none;
}

.admin-btn {
    position: fixed;
    bottom: 15px;
    left: 15px;
    background: #8b6f50;
    color: #f5e6d3;
    padding: 8px 15px;
    border-radius: 20px;
    text-decoration: none;
    font-size: 0.8rem;
    opacity: 0.3;
    transition: opacity 0.3s;
    z-index: 999;
}

.admin-btn:hover {
    opacity: 1;
}

.bio-row {
    display: flex;
    align-items: flex-start;
    gap: 1.5rem;
    background: rgba(228, 179, 129, 0.1);
    padding: 1.5rem;
    border-right: 6px solid #e4b381;
    margin-bottom: 1rem;
}

.bio-icon {
    font-size: 2rem;
    color: #b89b7b;
    min-width: 50px;
    text-align: center;
}

.bio-text p {
    font-size: 1.1rem;
    line-height: 2;
    text-align: justify;
}

.bio-header {
    text-align: center;
    margin-bottom: 1.5rem;
    border-bottom: 3px dashed #b89b7b;
    padding-bottom: 1rem;
}

.bio-header h2 {
    font-size: 2rem;
    color: #3e2c1b;
}

.bio-header h3 {
    font-size: 1.5rem;
    color: #6b4f32;
}

.bio-close-btn {
    background: #8b6f50;
    color: #f5e6d3;
    padding: 0.6rem 1.5rem;
    border-radius: 30px;
    font-size: 1rem;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.teacher-row .bio-text img {
    max-width: 250px;
    border: 4px double #b89b7b;
    padding: 0.5rem;
    background: #faf3e8;
    margin-top: 1rem;
    border-radius: 8px;
}

.no-poems {
    text-align: center;
    padding: 3rem;
    grid-column: 1 / -1;
    color: #8b6f50;
    font-size: 1.2rem;
    background: #faf3e8;
    border-radius: 24px;
    margin: 2rem;
}

.poet-image-caption {
    margin-top: 0.5rem;
    font-size: 0.9rem;
    color: #6b4f32;
    text-align: center;
}

.scroll-top {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: #8b6f50;
    color: #f5e6d3;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    transition: opacity 0.3s;
    z-index: 998;
    border: none;
    font-size: 1.2rem;
}

.scroll-top.visible {
    opacity: 0.7;
}

.scroll-top:hover {
    opacity: 1;
}

/* Loading spinner */
.fa-spin {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ========== RESPONSIVE DESIGN ========== */

/* Tablet */
@media (max-width: 992px) {
    .header {
        padding: 0.8rem 1.5rem;
    }
    .nav-container {
        gap: 1rem;
    }
    .logo {
        font-size: 1.8rem;
    }
    .music-control {
        padding: 0.4rem 1rem;
        gap: 0.5rem;
    }
    .volume-slider {
        width: 80px;
    }
}

/* Mobile Landscape */
@media (max-width: 768px) {
    .header {
        padding: 0.8rem 1rem;
    }
    .nav-container {
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 0.8rem;
    }
    .nav-left, .nav-right {
        width: 100%;
        text-align: center;
    }
    .logo {
        font-size: 1.6rem;
        white-space: normal;
        display: inline-block;
    }
    .music-control {
        width: 100%;
        justify-content: center;
        flex-wrap: wrap;
        padding: 0.5rem 1rem;
        gap: 0.5rem;
    }
    .music-status {
        font-size: 0.75rem;
    }
    .main-content {
        margin-top: 130px;
        padding: 0 1rem;
    }
    .music-message {
        top: 115px;
        font-size: 0.8rem;
        padding: 0.5rem 1.5rem;
        white-space: nowrap;
    }
    @keyframes slideDown {
        from { top: 85px; opacity: 0; transform: translateX(-50%) scale(0.9); }
        to { top: 115px; opacity: 1; transform: translateX(-50%) scale(1); }
    }
    .poems-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
        margin: 1rem auto;
    }
    .poem-lines-wrapper {
        width: 100% !important;
        min-width: auto !important;
    }
    .biography-section {
        padding: 1rem;
        margin: 1rem auto;
        width: calc(100% - 1rem);
    }
    .biography-section::before,
    .biography-section::after {
        font-size: 25px;
        top: -15px;
    }
    .bio-row {
        flex-direction: column;
        gap: 0.8rem;
        padding: 1rem;
    }
    .bio-icon {
        font-size: 1.5rem;
        min-width: auto;
        text-align: center;
    }
    .bio-text p {
        font-size: 0.95rem;
        line-height: 1.8;
        text-align: justify;
    }
    .bio-header h2 {
        font-size: 1.5rem;
    }
    .bio-header h3 {
        font-size: 1.2rem;
    }
    .bio-close-btn {
        padding: 0.4rem 1rem;
        font-size: 0.9rem;
    }
    .teacher-row .bio-text img {
        max-width: 150px;
    }
    .about-section {
        padding: 1rem;
        width: calc(100% - 1rem);
    }
    .about-section h1 {
        font-size: 1.3rem;
    }
    .couplet-line {
        font-size: 0.95rem;
        padding: 0.2rem 0.5rem;
    }
    .bismillah-text {
        font-size: 1.3rem;
    }
    .search-box {
        padding: 0.3rem 0.3rem 0.3rem 0.8rem;
    }
    .search-box input {
        padding: 0.7rem 0;
        font-size: 0.9rem;
    }
    .clear-btn {
        width: 28px;
        height: 28px;
    }
    .pagination-container {
        flex-direction: column;
        gap: 0.5rem;
    }
    .page-nav-large {
        font-size: 0.9rem;
        padding: 0.4rem 1rem;
    }
    .page-link {
        padding: 0.3rem 0.7rem;
        min-width: 35px;
        font-size: 0.85rem;
    }
    .card-footer {
        justify-content: center;
    }
    .poet-signature {
        width: 100%;
        justify-content: center;
        margin-top: 0.3rem;
    }
}

/* Small Mobile */
@media (max-width: 600px) {
    .logo {
        font-size: 1.4rem;
    }
    .music-control {
        flex-wrap: wrap;
        justify-content: center;
        border-radius: 30px;
        gap: 0.5rem;
        padding: 0.5rem 0.8rem;
    }
    .music-btn, .upload-btn, .reset-btn {
        width: 32px;
        height: 32px;
        font-size: 0.8rem;
    }
    .volume-control {
        order: 3;
        width: 100%;
        justify-content: center;
        margin-top: 0.2rem;
        padding: 0.2rem 0.6rem;
    }
    .volume-slider {
        width: 100px;
    }
    .volume-value {
        font-size: 0.7rem;
        min-width: 32px;
    }
    .music-status {
        display: inline-block;
        font-size: 0.7rem;
    }
    .main-content {
        margin-top: 150px;
    }
    .music-message {
        top: 135px;
        font-size: 0.7rem;
        padding: 0.4rem 1rem;
        white-space: nowrap;
    }
    @keyframes slideDown {
        from { top: 105px; opacity: 0; transform: translateX(-50%) scale(0.9); }
        to { top: 135px; opacity: 1; transform: translateX(-50%) scale(1); }
    }
    .biography-section {
        padding: 0.8rem;
    }
    .bio-text p {
        font-size: 0.85rem;
    }
    .bio-header h2 {
        font-size: 1.3rem;
    }
    .bio-header h3 {
        font-size: 1rem;
    }
    .search-info {
        font-size: 0.8rem;
        padding: 0.6rem 1rem;
    }
}

/* Extra Small */
@media (max-width: 480px) {
    .logo {
        font-size: 1.2rem;
    }
    .music-control {
        gap: 0.4rem;
        padding: 0.4rem 0.6rem;
    }
    .music-btn, .upload-btn, .reset-btn {
        width: 28px;
        height: 28px;
        font-size: 0.7rem;
    }
    .volume-slider {
        width: 70px;
    }
    .main-content {
        margin-top: 160px;
        padding: 0 0.8rem;
    }
    .music-message {
        top: 145px;
        font-size: 0.65rem;
        padding: 0.3rem 0.8rem;
    }
    @keyframes slideDown {
        from { top: 115px; opacity: 0; transform: translateX(-50%) scale(0.9); }
        to { top: 145px; opacity: 1; transform: translateX(-50%) scale(1); }
    }
    .search-box {
        padding: 0.2rem 0.2rem 0.2rem 0.6rem;
    }
    .search-box input {
        padding: 0.6rem 0;
        font-size: 0.85rem;
    }
    .search-icon {
        font-size: 0.9rem;
    }
    .clear-btn {
        width: 26px;
        height: 26px;
        font-size: 0.7rem;
    }
}


/* ========== LIKE BUTTON STYLES ========== */
.like-btn {
    background: none;
    border: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.2rem 0.8rem;
    border-radius: 30px;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    color: #e74c3c;
    background: rgba(231, 76, 60, 0.1);
}

.like-btn i {
    font-size: 1rem;
    transition: transform 0.2s ease;
}

.like-btn .like-count {
    font-size: 0.85rem;
    font-weight: bold;
    color: #e74c3c;
}

.like-btn:hover {
    background: rgba(231, 76, 60, 0.2);
    transform: scale(1.05);
}

.like-btn:hover i {
    transform: scale(1.1);
}

.like-btn.liked {
    animation: heartBeat 0.3s ease;
}

@keyframes heartBeat {
    0% { transform: scale(1); }
    50% { transform: scale(1.3); }
    100% { transform: scale(1); }
}

/* Card footer responsive for like button */
@media (max-width: 600px) {
    .card-footer {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .like-btn {
        padding: 0.2rem 0.6rem;
        font-size: 0.8rem;
    }
    
    .like-btn i {
        font-size: 0.85rem;
    }
}