* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    padding: 0;
    background: #f5f5f5;
    color: #333;
    font-family: Arial, sans-serif;
}

img {
    max-width: 100%;
    height: auto;
}

/* =========================
   HEADER MENU
========================= */

.site-header {
    position: sticky;
    top: 0;
    z-index: 9999;
    width: 100%;
    background: linear-gradient(268deg, #541114 0%, #c72127 100%);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.16);
}

.site-nav {
    max-width: 1180px;
    min-height: 64px;
    margin: 0 auto;
    padding: 0 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.site-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: #fff;
    font-size: 18px;
    font-weight: 700;
    text-decoration: none;
    white-space: nowrap;
}

.site-logo:hover {
    color: #fff;
    text-decoration: none;
}

.site-logo img {
    width: 80px;
    height: 80px;
    object-fit: contain;
}

.site-menu {
    display: flex;
    align-items: center;
    gap: 8px;
}

.site-menu a {
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
    padding: 10px 14px;
    border-radius: 999px;
    transition: background 0.25s ease, color 0.25s ease, transform 0.25s ease;
}

.site-menu a:hover {
    background: rgba(255, 255, 255, 0.16);
    color: #fff;
    text-decoration: none;
    transform: translateY(-1px);
}

.menu-toggle {
    display: none;
}

.menu-icon {
    display: none;
    margin: 0;
    color: #fff;
    font-size: 24px;
    cursor: pointer;
}

/* =========================
   ANCHOR TAB
========================= */

.section-anchor {
    position: relative;
    top: -90px;
    height: 0;
    overflow: hidden;
}

#bao-gia,
#cap-nhat,
#ty-gia-website {
    scroll-margin-top: 90px;
}

/* =========================
   MAIN LAYOUT
========================= */

.main-content {
    padding-top: 30px;
    padding-bottom: 40px;
}

.rate-note {
    max-width: 1100px;
    margin: 30px auto 40px;
    padding: 20px 25px;
    background: #fff5f5;
    border-left: 6px solid #c72127;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
}

.rate-note h4 {
    color: #9a0000;
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 18px;
}

.rate-note p {
    margin-bottom: 14px;
    font-size: 15px;
}

.rate-note a {
    color: #c72127;
    font-weight: 700;
    text-decoration: none;
}

.rate-note a:hover {
    color: #9a0000;
    text-decoration: underline;
}

.rate-row {
    display: flex;
    gap: 20px;
    margin-bottom: 12px;
}

.rate-col {
    flex: 1;
    background: #fff;
    padding: 12px 15px;
    border-radius: 6px;
    box-shadow: inset 0 0 0 1px #f0d6d6;
}

.label {
    display: block;
    color: #777;
    font-size: 13px;
    margin-bottom: 6px;
}

.label-space {
    margin-top: 12px;
}

.value {
    font-size: 16px;
    font-weight: 700;
}

.value.old {
    color: #999;
}

.value.new,
.value.new.original,
.value.new.viet,
.value.new.en {
    color: #c72127;
}

.value.highlight {
    color: #9a0000;
}

.arrow {
    margin: 0 6px;
    font-weight: 700;
}

.inline {
    color: #333;
    font-size: 14px;
    line-height: 1.6;
}

.inline b {
    color: #9a0000;
}

.lookup-link {
    margin-top: 18px;
}

/* =========================
   PRODUCT CARD
========================= */

#row {
    margin-top: 45px;
}

.quote-card-row {
    scroll-margin-top: 90px;
}

.card-offset {
    margin-top: -40px;
}

.product-card {
    position: relative;
    min-height: 100%;
    margin-bottom: 20px;
    padding: 20px;
    background-color: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.10);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.20);
}

.product-image {
    text-align: center;
    margin-bottom: 15px;
}

.product-image img {
    max-width: 100%;
    border-radius: 6px;
    transition: transform 0.3s ease;
}

.product-image img:hover {
    transform: scale(1.05);
}

.product-title {
    min-height: 48px;
    margin-bottom: 10px;
    color: #333;
    font-size: 20px;
    font-weight: 700;
    text-align: center;
}

.product-title a {
    color: #9a0000;
    font-weight: 700;
    text-decoration: none;
}

.product-title a:hover {
    color: #c72127;
    text-decoration: none;
}

.product-description {
    min-height: 44px;
    margin-bottom: 15px;
    color: #666;
    font-size: 15px;
    text-align: center;
}

.product-card small {
    display: block;
    padding-right: 48px;
    color: rgb(129, 4, 4);
    font-size: 11px;
}

.edit-button {
    position: absolute;
    right: 15px;
    bottom: 15px;
    width: 40px;
    height: 40px;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: visible;
    color: #fff;
    background-color: #c72127;
    border-radius: 50%;
    font-size: 20px;
    cursor: pointer;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.10);
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.edit-button:hover {
    color: #fff;
    background-color: #ff9800;
    text-decoration: none;
    transform: scale(1.1);
}

.edit-button:hover::before {
    content: "Truy cập";
    position: absolute;
    top: -35px;
    right: -20px;
    padding: 5px 10px;
    color: #fff;
    background-color: #c72127;
    border-radius: 4px;
    font-size: 14px;
    white-space: nowrap;
    opacity: 0.9;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.10);
}

.preview-image {
    display: none;
    position: absolute;
    top: -200px;
    width: 650px;
    max-width: 650px;
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    z-index: 20;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.22);
}

.preview-image1 {
    left: -450px;
}

.preview-image2 {
    left: -460px;
}

.preview-image3 {
    left: -500px;
}

.preview-image img {
    width: 100%;
    height: auto;
    display: block;
}

.edit-button:hover .preview-image {
    display: block;
}

/* =========================
   MODULE UPDATE
========================= */

.module-update-note {
    margin: 34px 0 18px;
    padding: 18px 22px;
    background: #fff;
    border-left: 6px solid #c72127;
    border-radius: 8px;
    box-shadow: inset 0 0 0 1px #f0d6d6, 0 4px 10px rgba(0, 0, 0, 0.06);
}

.module-update-time {
    margin-bottom: 10px;
    padding: 8px 12px;
    color: #555;
    background: #fff5f5;
    border: 1px solid #f0d6d6;
    border-radius: 6px;
    font-size: 14px;
    font-style: italic;
}

.module-update-time strong {
    color: #9a0000;
    font-weight: 700;
    font-style: normal;
}

.module-update-note h4 {
    margin: 0 0 14px;
    color: #9a0000;
    font-size: 18px;
    font-weight: 700;
}

.module-update-list {
    margin: 0 0 18px;
    padding-left: 20px;
}

.module-update-list:last-child {
    margin-bottom: 0;
}

.module-update-list li {
    margin-bottom: 10px;
    color: #333;
    font-size: 15px;
    line-height: 1.6;
}

.module-update-list li:last-child {
    margin-bottom: 0;
}

.module-update-list strong {
    color: #9a0000;
    font-weight: 700;
}

.module-update-list em {
    color: #555;
    font-style: italic;
    font-weight: 600;
}

.module-update-list b {
    color: #c72127;
    font-weight: 700;
}

/* =========================
   WEBSITE RATE
========================= */

.website-rate-note {
    margin-top: 0;
}

.website-rate-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
}

.website-rate-item {
    padding: 10px;
    background: #fffafa;
    border-radius: 6px;
    border: 1px solid #f0d6d6;
}

.website-rate-item .value {
    display: block;
    line-height: 1.6;
}

/* =========================
   OLD FORM SUPPORT
========================= */

.quote-section {
    max-width: 600px;
    margin: 40px auto;
    padding: 20px;
    background-color: #f9f9f9;
    border-radius: 10px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.10);
}

.quote-title {
    color: #333;
    font-size: 24px;
    font-weight: 700;
    text-align: center;
}

.currency-switcher {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    margin-bottom: 20px;
}

.currency-switcher span {
    margin-right: 10px;
    color: #555;
    font-size: 16px;
}

.currency-btn {
    padding: 10px 20px;
    color: #fff;
    background-color: #c72127;
    border: 0;
    border-radius: 5px;
    font-size: 12px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.currency-btn:hover {
    background-color: #ab1419;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    color: #333;
    font-size: 16px;
}

.form-control {
    width: 100%;
    padding: 10px;
    color: #333;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 14px;
    transition: border-color 0.3s ease;
}

.form-control:focus {
    border-color: #007bff;
    outline: none;
    box-shadow: 0 0 5px rgba(0, 123, 255, 0.5);
}

.small-text {
    color: red;
    font-size: 15px;
}

.coming-soon {
    color: #e53935;
    font-size: 15px;
    font-weight: 700;
    text-align: center;
}

/* =========================
   RESPONSIVE
========================= */

@media (max-width: 1199px) {
    .site-nav {
        max-width: 960px;
    }

    .site-menu a {
        padding: 10px 10px;
        font-size: 13px;
    }

    .preview-image {
        width: 520px;
        max-width: 520px;
    }

    .preview-image1 {
        left: -380px;
    }

    .preview-image2 {
        left: -390px;
    }

    .preview-image3 {
        left: -420px;
    }
}

@media (max-width: 991px) {
    .site-nav {
        max-width: 720px;
    }

    .menu-icon {
        display: block;
    }

    .site-menu {
        position: absolute;
        top: 64px;
        left: 0;
        right: 0;
        display: none;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        background: #741417;
        border-top: 1px solid rgba(255, 255, 255, 0.16);
    }

    .site-menu a {
        padding: 14px 20px;
        border-radius: 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.12);
        font-size: 14px;
    }

    .site-menu a:hover {
        transform: none;
    }

    .menu-toggle:checked ~ .site-menu {
        display: flex;
    }

    .section-anchor {
        top: -76px;
    }

    .rate-row {
        flex-direction: column;
        gap: 12px;
    }

    .card-offset {
        margin-top: 0;
    }

    .product-card {
        margin-bottom: 30px;
    }

    .preview-image {
        display: none !important;
    }

    .edit-button:hover::before {
        display: none;
    }

    .website-rate-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 767px) {
    .main-content {
        padding-top: 20px;
    }

    .rate-note {
        margin: 20px auto 28px;
        padding: 18px;
    }

    .rate-note h4 {
        font-size: 18px;
    }

    #row {
        margin-top: 20px;
    }

    .product-title {
        min-height: auto;
        font-size: 18px;
    }

    .product-description {
        min-height: auto;
    }

    .quote-section {
        margin: 25px auto;
    }

    .module-update-note {
        margin-top: 28px;
    }
}

@media (max-width: 576px) {
    .site-nav {
        min-height: 58px;
        padding: 0 12px;
    }

    .site-logo span {
        font-size: 15px;
    }

    .site-logo img {
        width: 28px;
        height: 28px;
    }

    .site-menu {
        top: 58px;
    }

    .section-anchor {
        top: -70px;
    }

    .rate-note {
        padding: 15px;
        border-left-width: 4px;
    }

    .rate-col {
        padding: 12px;
    }

    .label {
        font-size: 12px;
    }

    .value {
        font-size: 15px;
    }

    .inline {
        font-size: 13px;
    }

    .module-update-note {
        padding: 15px;
        border-left-width: 4px;
    }

    .module-update-note h4 {
        font-size: 16px;
    }

    .module-update-list li {
        font-size: 14px;
    }

    .product-card {
        padding: 16px;
    }

    .product-card small {
        padding-right: 44px;
    }

    .edit-button {
        width: 38px;
        height: 38px;
        font-size: 18px;
    }
}