:root {
    --bs-body-font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --brand-blue: #0F2C59;
    --brand-blue-hover: #1B4280;
    --brand-red: #E53935;
    --brand-red-hover: #C62828;
    --brand-light-bg: #F8FAFC;
}

body {
    background-color: #f1f5f9;
}

/* Custom Brand Buttons */
.btn-brand-primary {
    background-color: var(--brand-blue);
    border-color: var(--brand-blue);
    color: #ffffff;
    font-weight: 600;
}

.btn-brand-primary:hover, .btn-brand-primary:focus {
    background-color: var(--brand-blue-hover);
    border-color: var(--brand-blue-hover);
    color: #ffffff;
}

.btn-brand-outline {
    background-color: #ffffff;
    border: 2px solid #cbd5e1;
    color: var(--brand-blue);
    font-weight: 600;
}

.btn-brand-outline:hover {
    border-color: var(--brand-blue);
    background-color: #eff6ff;
    color: var(--brand-blue);
}

.brand-text-red {
    color: var(--brand-red);
}

/* Hero Image Cards */
.hero-card {
    position: relative;
    border-radius: 1rem;
    overflow: hidden;
    height: 350px;
}

.hero-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.hero-card:hover img {
    transform: scale(1.05);
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.85) 0%, rgba(0, 0, 0, 0.2) 60%, rgba(0, 0, 0, 0.1) 100%);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 1.25rem;
    color: #ffffff;
}

.schedule-card {
    border-radius: 0.75rem;
    padding: 0.85rem;
    margin-bottom: 0.75rem;
    text-align: left;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.schedule-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* Nav Pills Styling */
.nav-pills .nav-link {
    color: #475569;
    font-weight: 600;
    font-size: 0.875rem;
    border-radius: 0.5rem;
    background-color: #e2e8f0;
    margin-right: 0.25rem;
    margin-bottom: 0.25rem;
}

.nav-pills .nav-link.active {
    background-color: var(--brand-blue);
    color: #ffffff;
}

.toast-container-custom {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1080;
}

.extra-small {
    font-size: 0.75rem;
}

.tracking-wider {
    letter-spacing: 0.05em;
}

.fw-black {
    font-weight: 900;
}

.card .text-secondary h1:first-child, 
.card .text-secondary .h1:first-child,
.card .text-secondary h2:first-child, 
.card .text-secondary .h2:first-child {
    font-weight: 900 !important;
    color: #212529 !important;
    margin-top: 0.25rem;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #dee2e6;
}

.card .text-secondary h1:not(:first-child),
.card .text-secondary .h1:not(:first-child),
.card .text-secondary h2:not(:first-child),
.card .text-secondary .h2:not(:first-child) {
    font-weight: 900 !important;
    color: #212529 !important;
    margin-top: 2rem;
    margin-bottom: 1rem;
}

h3, .h3 {
    font-weight: 800;
    color: #212529;
    margin-top: 0.75rem;
}

.rounded-4 {
    border-radius: 1.5rem !important;
}

/* Navbar dropdown styles - Copied from ojk.css to support 3 levels */
.nav-item-container {
    display: flex;
    align-items: center;
}

@media (min-width: 992px) {
    .navbar-nav .nav-link,
    .navbar-nav .nav-item-container {
        text-align: center;
        justify-content: center;
    }
}

.nav-item-container .nav-link {
    margin-right: 5px;
}

.navbar .logo img {
    width: 100px;
    height: auto;
}

.dropdown-indicator {
    padding: 0.5rem 0.5rem;
    font-size: 0.8rem;
    color: rgba(0, 0, 0, 0.55);
    text-decoration: none;
    cursor: pointer;
}

.dropdown-indicator:hover {
    color: rgba(0, 0, 0, 0.7);
}

.dropdown-indicator::after {
    display: inline-block;
    margin-left: 0.255em;
    vertical-align: 0.255em;
    content: "";
    border-top: 0.3em solid;
    border-right: 0.3em solid transparent;
    border-bottom: 0;
    border-left: 0.3em solid transparent;
}

.dropdown:hover > .dropdown-menu {
    display: block;
}

.dropdown-submenu {
    position: relative;
}

.dropdown-submenu > .dropdown-menu {
    top: 0;
    left: 100%;
    margin-top: -6px;
    margin-left: -1px;
    border-radius: 0 6px 6px 6px;
}

.dropdown-submenu:hover > .dropdown-menu {
    display: block;
}

.dropdown-submenu > a:after {
    display: block;
    content: " ";
    float: right;
    width: 0;
    height: 0;
    border-color: transparent;
    border-style: solid;
    border-width: 5px 0 5px 5px;
    border-left-color: #ccc;
    margin-top: 5px;
    margin-right: -10px;
}

.dropdown-submenu:hover > a:after {
    border-left-color: #fff;
}

.leading-relaxed {
    line-height: 1.625;
}

.space-y-3 > :not([hidden]) ~ :not([hidden]) {
    margin-top: 1rem;
}

.space-y-4 > :not([hidden]) ~ :not([hidden]) {
    margin-top: 1.5rem;
}

.items-start {
    align-items: flex-start;
}

/* Table styling - reduced spacing */
.card .table,
.card table {
    margin-bottom: 0.5rem;
}

.card .table > :not(caption) > * > *,
.card table > :not(caption) > * > * {
    padding: 0.5rem 0.5rem;
}

/* Gallery Redesign overrides */
.ojk-gallery-inline {
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.ojk-gallery-inline .main {
    border-radius: 1.5rem !important; /* matches rounded-4 */
    aspect-ratio: 16 / 9; /* more modern aspect ratio than 4/3 */
}

.ojk-gallery-inline .thumb {
    border-radius: 0.75rem !important; /* rounded-3 */
}

.ojk-gallery-inline .control {
    border-radius: 0.5rem;
}

.card .table-sm > :not(caption) > * > *,
.card table.table-sm > :not(caption) > * > * {
    padding: 0.25rem 0.25rem;
}

/* Ensure CMS-generated tables within redesigned cards are also compact */
.card .text-secondary table {
    width: 100%;
    border-collapse: collapse;
}

.card .text-secondary td,
.card .text-secondary th {
    padding: 0.4rem 0.5rem;
    line-height: 1.4;
}

/* Footer styling */
footer a {
    color: rgba(255, 255, 255, 0.5);
    text-decoration: none;
    transition: color 0.2s ease;
}

footer a:hover {
    color: #ffffff;
}

footer h1, footer h2, footer h3, footer h4, footer h5, footer h6 {
    color: #ffffff;
    font-weight: 700;
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

footer ul {
    padding-left: 0;
    list-style: none;
    margin-bottom: 0;
}

footer ul li {
    margin-bottom: 0.25rem;
}

footer p {
    margin-bottom: 0.5rem;
}