/*
Theme Name: hade
Theme URI: https://underscores.me/
Author: underscore.me
Author URI: https://underscores.me/
Description: Mô tả ngắn về theme của bạn.
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: hade
Tags: custom-background, custom-logo, custom-menu, featured-images, threaded-comments, translation-ready

Đây là file CSS chính cho theme hade.
*/

/* ==========================================================================
   1. Cài đặt chung & Typography
   ========================================================================== */
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa; /* Màu nền xám rất nhạt */
}

a {
    color: #0d6efd; /* Màu link Bootstrap mặc định */
    text-decoration: none;
}

a:hover {
    color: #0a58ca;
    text-decoration: underline;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
}

.container {
    max-width: 1140px;
}

/* ==========================================================================
   2. Header & Navigation
   ========================================================================== */
.navbar-brand {
    font-weight: 700;
    font-size: 1.5rem;
}

.navbar .navbar-nav .nav-link {
    font-weight: 500;
}

/* -- Bắt đầu CSS cho Menu Bootstrap -- */

/* Căn chỉnh menu con (dropdown) */
.navbar-nav .dropdown-menu {
    border-radius: 0.25rem;
    border: 1px solid rgba(0,0,0,.15);
    box-shadow: 0 0.5rem 1rem rgba(0,0,0,.15);
}

/* Hiển thị menu con khi di chuột vào (chỉ cho màn hình lớn) */
@media (min-width: 992px) {
    .navbar-nav .nav-item.dropdown:hover > .dropdown-menu {
        display: block;
        margin-top: 0; /* Bỏ khoảng cách thừa */
    }
}

@media (max-width: 768px) {
    .lyric_footer {
        display: none; /* Ẩn phần này */
    }
}


/* -- Kết thúc CSS cho Menu Bootstrap -- */


/* ==========================================================================
   3. Khu vực nội dung chính
   ========================================================================== */
.content-area {
    background-color: #ffffff;
    padding: 2rem;
    border-radius: 0.25rem;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
}

article .entry-title a {
    text-decoration: none;
}

article .entry-title a:hover {
    color: #0a58ca;
}

/* ==========================================================================
   4. Trang chi tiết bài hát (single-hop-am.php)
   ========================================================================== */
.single-hop-am .entry-title {
    margin-bottom: 0.5rem;
}

.single-hop-am .entry-meta {
    font-size: 0.9rem;
    color: #6c757d;
}

.lyrics-content {
    font-family: "Courier New", Courier, monospace;
    font-size: 1rem;
    line-height: 1.8;
    white-space: pre-wrap; /* Giúp xuống dòng tự động */
    word-wrap: break-word;
    color: #212529;
}

/* --- BẮT ĐẦU CSS CHO HỢP ÂM TƯƠNG TÁC --- */
.lyric_chord {
    font-weight: 700;
    color: #d63384; /* Màu hồng đậm cho hợp âm */
    cursor: pointer; /* Biến con trỏ thành hình bàn tay */
    position: relative; /* Cần cho việc hiển thị tooltip sau này */
}

.lyric_chord:hover {
    color: #0d6efd; /* Đổi màu khi di chuột vào */
}

/* Hiển thị dấu ngoặc vuông */
.lyric_chord .chord-bracket {
    display: inline;
    opacity: 0.7; /* Làm mờ dấu ngoặc một chút */
}
/* --- KẾT THÚC CSS CHO HỢP ÂM TƯƠNG TÁC --- */


.performances-section h4 {
    margin-top: 2rem;
    border-bottom: 1px solid #eee;
    padding-bottom: 0.5rem;
}

/* ==========================================================================
   5. Sidebar & Widgets
   ========================================================================== */
.widget {
    background-color: #f8f9fa;
    padding: 1.5rem;
    border-radius: 0.25rem;
    margin-bottom: 1.5rem;
}

.widget-title {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    border-bottom: 2px solid #0d6efd;
    padding-bottom: 0.5rem;
}

.widget ul {
    list-style: none;
    padding-left: 0;
}

.widget ul li {
    margin-bottom: 0.5rem;
}

/* Tùy chỉnh cho widget Đám mây thẻ */
.widget.widget_tag_cloud .tagcloud a {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    margin: 0.2rem;
    background-color: #e9ecef;
    border-radius: 0.25rem;
    font-size: 0.9rem !important; /* Ghi đè kích thước font mặc định */
    text-decoration: none;
}

.widget.widget_tag_cloud .tagcloud a:hover {
    background-color: #0d6efd;
    color: #fff;
}

/* ==========================================================================
   6. Footer
   ========================================================================== */
.site-footer {
    background-color: #343a40;
    color: #f8f9fa;
    padding: 2rem 0;
    margin-top: 3rem;
    text-align: center; /* Thêm dòng này để căn giữa nội dung */
}

.site-footer a {
    color: #adb5bd;
}

.site-footer a:hover {
    color: #fff;
}

/* ... (toàn bộ nội dung CSS cũ của bạn) ... */

/* ================================================================
   CSS CHO TRANG BÀI HÁT (single-hop-am) - PHIÊN BẢN SỬA LỖI
   Hợp âm và lời trên cùng một dòng
   ================================================================ */

/* 1. Khung chứa lời bài hát */
#lyrics-display-wrapper {
    font-family: 'Verdana', sans-serif;
    font-size: 16px;
    line-height: 1.4; /* Tăng chiều cao dòng để có không gian cho hợp âm */
    background-color: #fdfdfd;
    padding: 25px;
    border-radius: 5px;
    border: 1px solid #eee;
}

/* 2. Các dòng tiêu đề đoạn (ĐK, 1, 2...) */
.lyric_section_header {
    font-weight: bold;
    color: #c0392b; /* Màu đỏ đô */
    margin-top: 1.5em;
    line-height: 1.5;
    padding-left: 0;
    text-indent: 0;
}

/* 3. Định dạng cho hợp âm */
.lyric_chord {
    display: inline; /* Hiển thị cùng dòng với lời */
    font-weight: bold;
    color: #d63384; /* Màu hồng đậm */
    cursor: pointer;
}

.lyric_chord:hover {
    color: #0d6efd;
}

/* 4. Định dạng cho metadata (như {time: 6/8}, {pattern: ...}) */
.lyric_metadata {
    font-family: 'Courier New', monospace;
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    padding: 8px 12px;
    margin: 8px 0;
    color: #495057;
    font-size: 0.9em;
    line-height: 1.4;
}

.lyric_metadata .metadata-type {
    color: #6c757d;
    font-weight: bold;
}

.lyric_metadata .metadata-value {
    color: #28a745;
    font-weight: normal;
}

.lyric_metadata .metadata-close {
    color: #6c757d;
}

/* Màu riêng cho từng loại metadata */
.lyric_metadata_time {
    border-left: 4px solid #17a2b8;
}

.lyric_metadata_pattern {
    border-left: 4px solid #ffc107;
}

.lyric_metadata_drum {
    border-left: 4px solid #dc3545;
}

.lyric_metadata_tempo {
    border-left: 4px solid #28a745;
}

.lyric_metadata_key {
    border-left: 4px solid #6610f2;
}

.lyric_metadata_capo {
    border-left: 4px solid #fd7e14;
}

/* 5. Định dạng cho thông tin đặc biệt (Tone C chơi theo, capo, ->>) */
.lyric_special_info {
    font-style: italic;
    color: #6c757d;
    background-color: #f8f9fa;
    padding: 6px 10px;
    border-radius: 3px;
    margin: 5px 0;
    border-left: 3px solid #28a745;
    font-size: 0.95em;
}

/* 6. Hiển thị dấu ngoặc vuông [ ] của hợp âm */
.chord-bracket {
    display: inline;
}

/* 5. Định dạng cho phần chữ lời bài hát */
.lyric_text .text {
    color: #212529; /* Màu chữ chính */
}

/* 6. Định dạng cho khu vực biểu đồ hợp âm */
#song_chords_diagram {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

#song_chords_diagram h4 {
    margin-bottom: 15px;
    font-size: 1.25rem;
}

#song_chords_diagram .song_chord_item {
    margin-right: 15px;
    margin-bottom: 15px;
}

#song_chords_diagram .chord_name {
    font-weight: bold;
    margin-top: 5px;
}


/* ================================================================
   GHI ĐÈ CSS ĐỂ BUỘC HIỂN THỊ THẾ TAY HỢP ÂM (JTAB)
   ================================================================ */

/* Đảm bảo vùng chứa biểu đồ luôn hiển thị khi được yêu cầu */
#song_chords_diagram {
    display: block !important; /* Buộc phải hiển thị dạng block */
    visibility: visible !important; /* Buộc phải nhìn thấy */
    opacity: 1 !important; /* Buộc không được trong suốt */
    height: auto !important; /* Chiều cao tự động */
    overflow: visible !important; /* Không ẩn nội dung bị tràn */
}

/* Đảm bảo từng biểu đồ con (được tạo bởi Jtab) cũng phải hiển thị */
#song_chords_diagram .song_chord_item,
#song_chords_diagram .jtab,
#song_chords_diagram .rendered,
#song_chords_diagram svg {
    display: inline-block !important; /* Buộc hiển thị */
    visibility: visible !important;
    opacity: 1 !important;
    vertical-align: top; /* Căn lề cho đẹp */
}

/* ==========================================================================
   7. CSS cho Phân trang (Pagination)
   ========================================================================== */
.pagination-container .page-numbers {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    gap: 0.5rem; /* Khoảng cách giữa các nút */
}

.pagination-container .page-numbers li {
    margin: 0;
}

.pagination-container .page-numbers a,
.pagination-container .page-numbers span {
    display: block;
    padding: 0.5rem 1rem;
    border: 1px solid #dee2e6;
    border-radius: 0.25rem;
    color: #0d6efd;
    text-decoration: none;
    transition: all 0.2s ease-in-out;
}

.pagination-container .page-numbers a:hover {
    background-color: #e9ecef;
    border-color: #adb5bd;
}

.pagination-container .page-numbers .current {
    background-color: #0d6efd;
    color: #fff;
    border-color: #0d6efd;
    cursor: default;
}

.pagination-container .page-numbers .dots {
    border: none;
    background-color: transparent;
    padding: 0.5rem 0.5rem;
}

/* ==========================================================================
   8. CSS cho Giao diện trang tĩnh (Giới thiệu, Chính sách...)
   ========================================================================== */
.static-page-content .entry-content {
    font-size: 1.1rem; /* Kích thước chữ lớn hơn một chút để dễ đọc */
    line-height: 1.8;
}

.static-page-content .entry-content h2,
.static-page-content .entry-content h3,
.static-page-content .entry-content h4 {
    margin-top: 2rem;
    margin-bottom: 1rem;
    font-weight: 600;
    border-bottom: 1px solid #eee;
    padding-bottom: 0.5rem;
}

.static-page-content .entry-content ul,
.static-page-content .entry-content ol {
    padding-left: 1.5rem;
    margin-bottom: 1.5rem;
}

.static-page-content .entry-content li {
    margin-bottom: 0.5rem;
}

.site-footer {
  background-color: #343a40;
  color: #f8f9fa;
  padding: 2rem 0;
  margin-top: 3rem;
  text-align: center;
  font-size: 0.9rem;
}

.site-footer .footer-nav a {
  color: #adb5bd;
  margin: 0 0.5rem;
  text-decoration: none;
}

.site-footer .footer-nav a:hover {
  color: #fff;
  text-decoration: underline;
}

.site-footer .footer-description {
  margin: 1rem 0;
  color: #adb5bd;
}

.site-footer .footer-note {
  color: #6c757d;
  font-size: 0.8rem;
}

/* ========================================================================
   404 PAGE – Hade theme (phiên bản hòa màu với site hiện tại)
   ======================================================================== */

/* Nền trang 404: giữ nền xám nhạt của site */
body.error404 {
  background-color: #f8f9fa;
}

/* Khối 404 */
.error-404 .hade-404 {
  max-width: 960px;
  margin: 40px auto;
  padding: 32px;
  background: #ffffff;
  border-radius: 0.25rem; /* bo góc nhẹ giống widget */
  box-shadow: 0 0.125rem 0.25rem rgba(0,0,0,.075);
}

/* Hero: chia cột linh hoạt */
.error-404 .hero {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 24px;
}

.error-404 .page-title {
  margin: 0 0 12px;
  font-size: clamp(28px, 4vw, 38px);
  line-height: 1.2;
}

.error-404 .hero p {
  margin: 0 0 16px;
  color: #6c757d; /* màu chữ phụ */
}

/* Form tìm kiếm */
.error-404 .search-form,
.error-404 form.search-form {
  display: flex;
  gap: 10px;
  align-items: stretch;
}

.error-404 .search-form .search-field,
.error-404 form.search-form input[type="search"] {
  flex: 1 1 auto;
  padding: 10px 12px;
  border: 1px solid #dee2e6;
  border-radius: 0.25rem;
}

.error-404 .search-form .search-submit,
.error-404 form.search-form input[type="submit"] {
  padding: 10px 16px;
  border: 1px solid #0d6efd;
  background: #0d6efd;
  color: #fff;
  border-radius: 0.25rem;
  cursor: pointer;
}

.error-404 .search-form .search-submit:hover {
  background: #0a58ca;
  border-color: #0a58ca;
}

/* Nút hành động */
.error-404 .actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 16px;
}

.error-404 .actions .btn {
  display: inline-block;
  padding: 10px 16px;
  border-radius: 0.25rem;
  text-decoration: none;
  border: 1px solid #dee2e6;
  background: #fff;
  color: #212529;
}

.error-404 .actions .btn:hover {
  background: #f3f4f6;
}

.error-404 .actions .btn--primary {
  border-color: #0d6efd;
  background: #0d6efd;
  color: #fff;
}

.error-404 .actions .btn--primary:hover {
  background: #0a58ca;
  border-color: #0a58ca;
}

/* Widget khu vực gợi ý */
.error-404 .widgets {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
  margin-top: 32px;
}

.error-404 .widget {
  background-color: #f8f9fa;
  padding: 1.25rem;
  border-radius: 0.25rem;
  border: 1px solid #e9ecef;
}

.error-404 .widget h2,
.error-404 .widget .widget-title {
  margin: 0 0 10px;
  font-size: 1.2rem;
  border-bottom: 2px solid #0d6efd;
  padding-bottom: 0.5rem;
}

/* Dropdown lưu trữ */
.error-404 .widget_archives select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #dee2e6;
  border-radius: 0.25rem;
}

/* Link trong widget */
.error-404 .widget ul li a {
  text-decoration: none;
}

.error-404 .widget ul li a:hover {
  text-decoration: underline;


/* Nền xám nhẹ toàn site để box trắng nổi bật */
body { background: #f7f7f9; }

/* Làm box nổi hơn một chút */
.container .row > .col-lg-8,
.container .row > .col-lg-4 {
    margin-bottom: 1.5rem;
}
.entry-content,
.widget,
.info-box,
#comments {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 12px rgba(0,0,0,.06);
    padding: 16px;
}
}
