:root {
    --primary-color: #2563eb;
}

body {
    font-family: "Times New Roman", system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
}

.container-fluid {
    max-width: 1440px;
}

/**
 * Multi-line text ellipsis (2 lines)
 */
.text-clamp-2 {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-clamp: 2;
}

/**
 * Multi-line text ellipsis (3 lines)
 */
.text-clamp-3 {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    line-clamp: 3;
}



/**
Header
 */
.header {
    position: sticky;
    top: 0;
    z-index: 1020;
    background-color: #fff;
    box-shadow: 0 1px 4px rgba(15, 23, 42, 0.06);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    min-height: auto;
    padding-top: 12px;
    padding-bottom: 12px;
    transition: min-height 0.3s ease, padding 0.3s ease, gap 0.3s ease;
}

.header-logo {
    display: inline-flex;
    align-items: center;
    max-width: 100%;
    text-decoration: none;
    flex-shrink: 0;
}

.header-logo-img {
    display: block;
    width: auto;
    height: 72px;
    object-fit: contain;
    transition: height 0.3s ease;
}

.header-nav {
    flex: 1;
    display: flex;
    justify-content: start;
}

.header-nav-list {
    display: flex;
    align-items: center;
    gap: 2.5rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.header-nav-link {
    position: relative;
    display: inline-block;
    padding: 0.25rem 0;
    font-weight: 400;
    color: #2d3748;
    text-decoration: none;
    transition: color 0.2s ease;
}

.header-nav-link::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: -4px;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transform: translateX(-50%);
    transition: width 0.25s ease, background-color 0.2s ease;
}

.header-nav-link:hover,
.header-nav-link.is-active {
    color: var(--primary-color);
}

.header-nav-link:hover::after,
.header-nav-link.is-active::after {
    width: 100%;
}

.header-nav-item.is-active > .header-nav-link {
    color: var(--primary-color);
}

.header-nav-sublist {
    display: none;
    margin: 0;
    padding: 0.5rem 0 0.25rem 1rem;
    list-style: none;
}

.header-nav-sublink {
    display: block;
    padding: 0.375rem 0;
    font-size: 0.9375rem;
    font-weight: 400;
    color: #64748b;
    text-decoration: none;
    transition: color 0.2s ease;
}

.header-nav-sublink:hover,
.header-nav-sublink.is-active {
    color: var(--primary-color);
}

.header-nav-item.is-active > .header-nav-sublist {
    display: block;
}

.header-login {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    min-width: 96px;
    padding: 0.5rem 1.5rem;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-weight: 500;
    color: #fff;
    text-decoration: none;
    background: linear-gradient(135deg, #1e68ad 0%, #3b7dd8 55%, #5a9de8 100%);
    border: none;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(30, 104, 173, 0.3);
    transition: filter 0.2s ease, box-shadow 0.2s ease;
}

.header-login:hover {
    filter: brightness(1.1);
    box-shadow: 0 4px 12px rgba(30, 104, 173, 0.38);
}

.header-login:active {
    filter: brightness(0.96);
}

.header-login-nav {
    display: none;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-shrink: 0;
}

.header-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 6px;
    width: 44px;
    height: 44px;
    padding: 0;
    border: none;
    border-radius: 8px;
    background: transparent;
    cursor: pointer;
    transition: background 0.2s ease;
}

.header-toggle:hover {
    background: rgba(30, 104, 173, 0.08);
}

.header-toggle-bar {
    display: block;
    width: 22px;
    height: 2.5px;
    margin: 0 auto;
    background-color: currentColor;
    border-radius: 2px;
    transition: transform 0.25s ease, opacity 0.2s ease;
}

.header.is-menu-open .header-toggle {
    background: rgba(30, 104, 173, 0.1);
}

.header.is-menu-open .header-toggle-bar:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.header.is-menu-open .header-toggle-bar:nth-child(2) {
    opacity: 0;
}

.header.is-menu-open .header-toggle-bar:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* Tablet: 768px - 991.98px */
@media (min-width: 768px) and (max-width: 991.98px) {
    .header-inner {
        gap: 1rem;
        min-height: 132px;
    }

    .header-logo-img {
        height: 108px;
    }

    .header-nav-list {
        gap: 1.25rem;
    }

    .header-login {
        min-width: 84px;
        padding: 0.4375rem 1.125rem;
    }
}

/* PC: >= 992px */
@media (min-width: 992px) {
    .header-inner {
        min-height: 186px;
    }

    .header-logo-img {
        height: 162px;
    }
}

/* Mobile: < 768px */
@media (max-width: 767.98px) {
    .header-inner {
        display: grid;
        grid-template-columns: 1fr auto 1fr;
        grid-template-rows: auto auto;
        align-items: center;
        gap: 0.75rem;
        padding-top: 10px;
        padding-bottom: 10px;
    }

    .header-logo {
        grid-column: 2;
        grid-row: 1;
        justify-self: center;
        max-width: 100%;
    }

    .header-logo-img {
        height: 72px;
    }

    .header-actions {
        grid-column: 3;
        grid-row: 1;
        justify-self: end;
        margin-left: 0;
    }

    .header-toggle {
        display: flex;
    }

    .header-login-bar {
        display: none;
    }

    .header-login-nav {
        display: inline-flex;
        width: 100%;
        min-width: 0;
        margin-top: 0.75rem;
        padding: 0.625rem 1rem;
    }

    .header-nav {
        display: flex;
        flex: none;
        flex-direction: column;
        grid-column: 1 / -1;
        grid-row: 2;
        justify-content: stretch;
        max-height: 0;
        opacity: 0;
        overflow: hidden;
        visibility: hidden;
        padding-top: 0;
        border-top: 1px solid transparent;
        transition: max-height 0.35s ease, opacity 0.25s ease, padding-top 0.35s ease, border-color 0.25s ease, visibility 0s linear 0.35s;
    }

    .header.is-menu-open .header-nav {
        max-height: 420px;
        opacity: 1;
        visibility: visible;
        padding-top: 0.25rem;
        border-top-color: #e8ecf0;
        transition: max-height 0.35s ease, opacity 0.25s ease, padding-top 0.35s ease, border-color 0.25s ease, visibility 0s;
    }

    .header-nav-list {
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        width: 100%;
    }

    .header-nav-item {
        border-bottom: 1px solid #f1f5f9;
    }

    .header-nav-item:last-child {
        border-bottom: none;
    }

    .header-nav-link {
        display: block;
        padding: 0.75rem 0.25rem;
        transition: color 0.2s ease, padding 0.25s ease;
    }

    .header-nav-link::after {
        left: 0;
        bottom: 0.5rem;
        transform: none;
        height: 2px;
        transition: width 0.25s ease;
    }

    .header-nav-link:hover::after,
    .header-nav-link.is-active::after {
        width: 2rem;
    }

    .header-nav-sublist {
        display: block;
        padding: 0.25rem 0 0.25rem 1rem;
    }

    .header-nav-sublink {
        padding: 0.625rem 0.25rem;
    }
}

/**
Footer
 */
.footer {
    background-color: #1e2430;
}

.footer-inner {
    padding-top: 1.5rem;
    padding-bottom: 1.5rem;
}

.footer-line {
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.88);
}

.footer-links {
    padding-top: 0.125rem;
}

.footer-link {
    color: rgba(255, 255, 255, 0.92);
    text-decoration: none;
    transition: color 0.2s ease;
}

.footer-link:hover {
    color: #fff;
    text-decoration: underline;
}

/* PC: >= 992px */
@media (min-width: 992px) {
    .footer-inner {
        padding-top: 2rem;
        padding-bottom: 2rem;
    }

    .footer-links {
        text-align: right;
    }
}

/* Tablet: 768px - 991.98px */
@media (min-width: 768px) and (max-width: 991.98px) {
    .footer-inner {
        padding-top: 1.75rem;
        padding-bottom: 1.75rem;
    }

    .footer-links {
        text-align: left;
    }
}

/* Mobile: < 768px */
@media (max-width: 767.98px) {
    .footer-inner {
        padding-top: 1.25rem;
        padding-bottom: 1.25rem;
    }

    .footer-aside {
        padding-top: 0.25rem;
        margin-top: 0.25rem;
        border-top: 1px solid rgba(255, 255, 255, 0.12);
    }

    .footer-links {
        padding-top: 0.75rem;
        text-align: left;
    }
}

/**
 * Pagination (nav.pagination overrides Bootstrap .pagination flex row)
 */
nav.pagination {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    gap: 0.875rem;
    margin-top: 2rem;
}

.pagination-list {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0.375rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.pagination-item {
    display: flex;
}

.pagination-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 2.5rem;
    height: 2.5rem;
    padding: 0 0.75rem;
    font-size: 0.9375rem;
    font-weight: 500;
    line-height: 1;
    color: #475569;
    text-decoration: none;
    background: #fff;
    border: 1px solid #dbe3ec;
    border-radius: 8px;
    transition: color 0.2s ease, border-color 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}

a.pagination-link:hover {
    color: var(--primary-color);
    border-color: #93c5fd;
    background: #eff6ff;
}

.pagination-item.is-active .pagination-link.is-current,
.pagination-link.is-current {
    color: #fff;
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    border-color: transparent;
    box-shadow: 0 4px 14px rgba(37, 99, 235, 0.25);
}

.pagination-item.is-disabled .pagination-link {
    color: #cbd5e1;
    background: #f8fafc;
    border-color: #e8ecf0;
    cursor: not-allowed;
}

.pagination-item.is-ellipsis .pagination-link {
    min-width: 2rem;
    padding: 0 0.375rem;
    color: #94a3b8;
    background: transparent;
    border-color: transparent;
}

.pagination-prev,
.pagination-next {
    min-width: 2.5rem;
    padding: 0;
}

.pagination-summary {
    margin: 0;
    font-size: 0.875rem;
    line-height: 1.5;
    color: #64748b;
    text-align: center;
}

@media (max-width: 767.98px) {
    .pagination-list {
        gap: 0.25rem;
    }

    .pagination-link {
        min-width: 2.25rem;
        height: 2.25rem;
        padding: 0 0.5rem;
        font-size: 0.875rem;
        border-radius: 6px;
    }

    .pagination-item-page.is-ellipsis {
        display: none;
    }

    .pagination-item-page:not(.is-active) {
        display: none;
    }

    .pagination-summary {
        font-size: 0.8125rem;
    }
}

/**
 * Breadcrumb
 */
.breadcrumb-wrap {
    padding-bottom: 1.25rem;
}

.breadcrumb-bar {
    padding: 1rem 1.25rem;
    background: #fff;
    border: 1px solid #e8ecf0;
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(15, 23, 42, 0.04);
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.25rem 0;
    margin: 0;
    padding: 0;
    list-style: none;
    font-size: 0.875rem;
    line-height: 1.5;
}

.breadcrumb-item {
    display: inline-flex;
    align-items: center;
    min-width: 0;
    max-width: 100%;
}

.breadcrumb-item + .breadcrumb-item::before {
    content: ">";
    margin: 0 0.5rem;
    color: #94a3b8;
}

.breadcrumb-item a {
    color: #64748b;
    text-decoration: none;
    transition: color 0.2s ease;
}

.breadcrumb-item a:hover {
    color: var(--primary-color);
}

.breadcrumb-item.is-current {
    flex: 1;
    min-width: 0;
}

.breadcrumb-current {
    display: block;
    overflow: hidden;
    font-weight: 500;
    color: #0f172a;
    text-overflow: ellipsis;
    white-space: nowrap;
}

@media (max-width: 767.98px) {
    .breadcrumb-wrap {
        padding-bottom: 1rem;
    }

    .breadcrumb-bar {
        padding: 0.875rem 1rem;
    }
}

/**
 * Empty state
 */
.empty-state {
    padding: 3rem 1.5rem;
    text-align: center;
    background: #fff;
    border: 1px solid #e8ecf0;
    border-radius: 12px;
}

.empty-state-icon {
    display: block;
    font-size: 3rem;
    line-height: 1;
    color: #cbd5e1;
}

.empty-state-title {
    margin: 1rem 0 0.5rem;
    font-size: 1.25rem;
    font-weight: 600;
    color: #0f172a;
}

.empty-state-desc {
    max-width: 28rem;
    margin: 0 auto;
    line-height: 1.6;
    color: #64748b;
}

.empty-state-action {
    display: inline-flex;
    align-items: center;
    margin-top: 1.25rem;
    padding: 0.5rem 1rem;
    font-size: 0.9375rem;
    font-weight: 500;
    color: #fff;
    text-decoration: none;
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    border-radius: 8px;
    box-shadow: 0 4px 14px rgba(37, 99, 235, 0.25);
    transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.empty-state-action:hover {
    color: #fff;
    box-shadow: 0 6px 18px rgba(37, 99, 235, 0.3);
}

@media (max-width: 767.98px) {
    .empty-state {
        padding: 2.5rem 1rem;
    }

    .empty-state-icon {
        font-size: 2.5rem;
    }

    .empty-state-title {
        font-size: 1.125rem;
    }
}

/**
 * Rich text content reset
 */
.content {
    font-size: 1rem;
    line-height: 1.75;
    color: #334155;
    word-break: break-word;
}

.content > :first-child {
    margin-top: 0;
}

.content > :last-child {
    margin-bottom: 0;
}

.content p {
    margin: 0 0 1rem;
}

.content h1,
.content h2,
.content h3,
.content h4,
.content h5,
.content h6 {
    margin: 1.5rem 0 0.75rem;
    font-weight: 600;
    line-height: 1.4;
    color: #0f172a;
}

.content h1 {
    font-size: 1.5rem;
}

.content h2 {
    font-size: 1.375rem;
}

.content h3 {
    font-size: 1.25rem;
}

.content h4 {
    font-size: 1.125rem;
}

.content ul,
.content ol {
    margin: 0 0 1rem;
    padding-left: 1.5rem;
}

.content li {
    margin-bottom: 0.375rem;
}

.content li > ul,
.content li > ol {
    margin-top: 0.375rem;
    margin-bottom: 0;
}

.content img {
    display: block;
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 0 auto;
}

.content a {
    color: var(--primary-color);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.content a:hover {
    color: #1d4ed8;
}

.content blockquote {
    margin: 0 0 1rem;
    padding: 0.75rem 1rem;
    color: #475569;
    background: #f8fafc;
    border-left: 4px solid #cbd5e1;
    border-radius: 0 8px 8px 0;
}

.content hr {
    margin: 1.5rem 0;
    border: 0;
    border-top: 1px solid #e2e8f0;
}

.content table {
    width: 100%;
    margin: 0 0 1rem;
    border-collapse: collapse;
    font-size: 0.9375rem;
}

.content th,
.content td {
    padding: 0.625rem 0.75rem;
    border: 1px solid #e2e8f0;
    text-align: left;
}

.content th {
    font-weight: 600;
    color: #0f172a;
    background: #f8fafc;
}

.content pre,
.content code {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    font-size: 0.875em;
}

.content pre {
    overflow-x: auto;
    margin: 0 0 1rem;
    padding: 0.875rem 1rem;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
}

.content :not(pre) > code {
    padding: 0.125rem 0.375rem;
    background: #f1f5f9;
    border-radius: 4px;
}

.content strong,
.content b {
    font-weight: 600;
    color: #0f172a;
}

.content iframe,
.content video {
    display: block;
    max-width: 100%;
    margin: 1rem 0;
    border: 0;
    border-radius: 8px;
}

