@import 'variables.css';

/* ===================== Base ===================== */
* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
    color: var(--text-main);
    background: #fcf4f121;
}

a {
    color: inherit;
    text-decoration: none;
}

h1, h2, h3 {
    margin: 0;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

ul, ol {
    list-style: none;
    margin: 0;
    padding: 0;
}

.page-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 32px 50px;
}

section {
    margin-top: 48px;
}

/* ===================== Navigation ===================== */
.main-nav {
    position: sticky;
    top: 0;
    z-index: 100;
    height: 72px;
    background: #ffffff;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.24);
    display: flex;
    align-items: center;
}

.nav-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
}

p.nav-logo {
    font-size: 0;
}

.nav-logo span {
    font-family: "Playfair Display", serif;
    font-size: 22px;
    font-weight: 700;
    color: var(--text-main);
}

.nav-logo img {
    height: 40px;
}

.nav-menu {
    display: flex;
    gap: 40px;
    align-items: center;
}

.nav-link {
    font-family: "Inter", system-ui, sans-serif;
    font-size: 16px;
    font-weight: 500;
    color: var(--text-main);
    text-decoration: none;
    position: relative;
    padding: 4px 0;
}

.nav-link::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: -4px;
    width: 0;
    height: 2px;
    border-radius: 999px;
    background: var(--primary);
    transform: translateX(-50%);
    transition: width 0.2s ease-out;
}

.nav-link:hover {
    color: var(--primary-dark);
}

.nav-link:hover::after {
    width: 60%;
}

.nav-link.is-active {
    color: var(--primary-dark);
}

.nav-link.is-active::after {
    width: 100%;
}

/* Hamburger button */
.nav-toggle {
    display: none;
    background: none;
    border: none;
    width: 40px;
    height: 40px;
    position: relative;
    cursor: pointer;
    z-index: 1000;
}

.nav-toggle span,
.nav-toggle span::before,
.nav-toggle span::after {
    content: "";
    position: absolute;
    width: 24px;
    height: 2px;
    background: var(--text-main);
    border-radius: 2px;
    transition: all 0.3s ease;
}

.nav-toggle span {
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.nav-toggle span::before {
    top: -8px;
    left: 0;
}

.nav-toggle span::after {
    bottom: -8px;
    left: 0;
}

.nav-toggle.active span {
    background: transparent;
}

.nav-toggle.active span::before {
    top: 0;
    transform: rotate(45deg);
}

.nav-toggle.active span::after {
    bottom: 0;
    transform: rotate(-45deg);
}

/* ===================== Back to Top ===================== */
.back-to-top {
    position: fixed;
    bottom: 32px;
    right: 32px;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: #ffffff;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    border: 1px solid #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.3s ease, transform 0.3s ease, background 0.3s ease;
    z-index: 1000;
    font-size: 18px;
    color: var(--text-main);
}

.back-to-top:hover {
    background: #f5f5f5;
    box-shadow: 0 8px 10px rgb(232 90 42);
    transform: translateY(-2px);
}

.back-to-top.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ===================== Footer ===================== */
.footer {
    background: #2f2a28;
    color: #f1ebe7;
    padding: 32px;
    /*margin-top: 56px;*/
}

.footer-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 2fr 2.5fr;
    gap: 24px;
    font-size: 14px;
    padding:0 32px;
}

.footer-logo {
    font-family: "Playfair Display", serif;
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 8px;
}

.footer-logo img {
    height: 40px;
}

.footer_bot_nav {
    display: grid;
    grid-template-columns: 1.5fr 1.5fr;
    gap: 24px;
}

.footer-nav,
.footer-legal {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.footer a {
    color: #f1ebe7;
    font-size: 14px;
}

.footer a:hover {
    color: var(--primary);
}

.footer-note {
    font-size: 13px;
    color: #d1c5be;
    margin-top: 8px;
}

.footer_bot {
    margin-top: 40px;
    text-align: center;
    border-top: 1px solid #3c3c3c;
    padding-top: 40px;
    font-size: 13px;
    color: #d1c5be;
}

/* ===================== Breadcrumb ===================== */
.breadcrumb {
    padding: 15px 0;
    margin-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.breadcrumb ol {
    display: flex;
    flex-wrap: wrap;
    list-style: none;
    padding: 0;
    margin: 0;
}

.breadcrumb li {
    display: inline-flex;
    align-items: center;
    font-size: 0.9rem;
    color: #666;
}

.breadcrumb li a:hover,
.breadcrumb li a:focus {
    color: var(--primary-dark);
}

.breadcrumb li:not(:last-child)::after {
    content: ">";
    margin: 0 8px;
    color: #999;
}

.breadcrumb li:last-child {
    color: #333;
    font-weight: 500;
}

/* ===================== Container (inner pages) ===================== */
.page-wrapper .container {
    display: flex;
    max-width: 1200px;
    margin: 0 auto;
    gap: 30px;
}

/* ===================== Sidebar ===================== */
.sidebar {
    width: 300px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.widget {
    background-color: #fff;
    padding: 20px;
    border-radius: 16px;
    border: 1px solid #f8aa8f;
}

.widget p {
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--primary-dark);
    font-size: 1.1rem;
}

.hot_list .item {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
    border-radius: 12px;
    transition: all 0.3s ease;
    position: relative;
}

.hot_list .item:last-child {
    margin-bottom: 0;
}

.hot_list .item:hover {
    transform: translateY(-3px);
}

.item_num {
    width: 20px;
    height: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    background: linear-gradient(135deg, #cccccc 0%, #767676 100%);
    color: #fff;
    font-size: 14px;
    font-weight: bold;
    border-radius: 50%;
    margin-right: 10px;
    flex-shrink: 0;
}

.hot_list .item:nth-of-type(1) .item_num,
.hot_list .item:nth-of-type(2) .item_num,
.hot_list .item:nth-of-type(3) .item_num {
    background: linear-gradient(135deg, #f0bdac 0%, #e85a2a 100%);
}

.hot_list .item .tit a {
    font-size: 16px;
    font-weight: bold;
}

.hot_list .item .tit a,
.list-item .tit a {
    color: #333;
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.hot_list .item .tit a:hover,
.hot_list .item .tit a:focus,
.list-item .tit a:hover,
.list-item .tit a:focus {
    color: var(--primary-dark);
}

.featured .feat_item {
    box-shadow: 6px 8px 9px -5px #8f8f8f;
    margin-bottom: 20px;
    overflow: hidden;
    border-radius: 5px;
}

.featured .feat_item img {
    max-height: 150px;
    height: auto;
    width: 100%;
    object-fit: cover;
    border-radius: 5px;
}

.featured .feat_item .tit {
    background-color: rgba(0, 0, 0, 0.6);
    border-bottom-left-radius: 5px;
    border-bottom-right-radius: 5px;
    height: 36px;
    margin-top: -40px;
    position: relative;
    color: #fff;
    line-height: 36px;
    padding: 0 10px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    display: block;
}

.featured .feat_item a:hover img {
    transition: all 0.2s linear;
    transform: scale(1.06);
}

.featured .feat_item a:hover .tit {
    text-decoration: underline;
}

/* ===================== Pagination ===================== */
.pagination {
    display: flex;
    justify-content: center;
    margin-top: 30px;
    gap: 5px;
}

.pagination a,
.pagination span {
    display: block;
    padding: 8px 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    color: #333;
}

.pagination a:hover,
.pagination a:focus,
.pagination .active {
    background-color: var(--primary-dark);
    color: #fff;
    border-color: var(--primary-dark);
}

.pagination .disabled {
    color: #ccc;
    cursor: not-allowed;
}

.pagination .ellipsis {
    border: none;
    padding: 8px 4px;
}

/* ===================== Responsive ===================== */
@media(max-width:1200px){
    .footer-inner{
        padding:0;
    }
}
@media (max-width: 900px) {
    .nav-toggle {
        display: block;
    }

    .nav-menu {
        display: none;
        position: absolute;
        top: 72px;
        left: 0;
        width: 100%;
        background: #ffffff;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
        padding: 24px 16px;
        border-radius: 0 0 20px 20px;
        flex-direction: column;
        gap: 24px;
        z-index: 100;
    }

    .nav-menu.active {
        display: flex;
        animation: fadeIn 0.3s ease;
    }

    .nav-link {
        width: 100%;
        text-align: center;
        padding: 12px 0;
        font-size: 18px;
    }

    .nav-link::after {
        display: none;
    }

    .footer-inner {
        grid-template-columns: 1fr 1fr;
    }

    .page-wrapper .container {
        flex-direction: column;
    }

    .sidebar {
        width: 100%;
    }
}

@media (max-width: 768px) {
    .nav-inner {
        padding: 0 16px;
    }

    .page-wrapper {
        padding: 0 16px 48px;
    }

    .footer-inner {
        grid-template-columns: 1fr;
    }

    .back-to-top {
        width: 48px;
        height: 48px;
        bottom: 16px;
        right: 16px;
    }
    .footer{
        padding:32px 16px;
    }
}
@media(min-width:1200px){
    .footer-inner{
        padding:0 32px;
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
.hero-illustration-inner img{
    height:100%;
    object-fit: cover;
}