/**
 * KMPS Theme - Custom Stylesheet (custom.css)
 * Contains KMPS-specific brand styling, components, and non-landing template rules.
 * Homepage sections strictly use landing.css system without conflicting overrides.
 *
 * @package KMPSTheme
 */

/* ========================================================
   0. KMPS Official Brand Palette & Bootstrap Overrides
   ======================================================== */
:root {
    --theme-primary: #17466a;
    --theme-primary-dark: #12335b;
    --theme-secondary: #2570b8;
    --theme-accent: #d9381e;
    --sps-blue: #17466a;
    --sps-blue-dark: #12335b;
    --sps-blue-cerulean: #2570b8;
    --sps-blue-sky: #38bdf8;
    --sps-flame-red: #d9381e;
    --sps-yellow: #f5a623;
    --sps-green: #1b4578;
    --sps-text: #173f62;
    --sps-text-muted: #516b7d;
}

/* Force Bootstrap color utilities to use KMPS Theme Palette */
.text-primary,
.text-primary-emphasis {
    color: var(--sps-blue-dark, #12335b) !important;
}

a.text-primary:hover,
a.text-primary:focus {
    color: var(--sps-flame-red, #d9381e) !important;
}

.bg-primary {
    background-color: var(--sps-blue, #17466a) !important;
}

.border-primary {
    border-color: var(--sps-blue, #17466a) !important;
}

.text-danger {
    color: var(--sps-flame-red, #d9381e) !important;
}

.bg-danger {
    background-color: var(--sps-flame-red, #d9381e) !important;
}

.text-success {
    color: var(--sps-green, #1b4578) !important;
}

.bg-success {
    background-color: var(--sps-green, #1b4578) !important;
}

.text-warning {
    color: var(--sps-yellow, #f5a623) !important;
}

.bg-warning {
    background-color: var(--sps-yellow, #f5a623) !important;
}

.text-info {
    color: #159eb2 !important;
}

.bg-info {
    background-color: #159eb2 !important;
}

.btn-primary {
    background-color: var(--sps-blue, #17466a) !important;
    border-color: var(--sps-blue, #17466a) !important;
    color: #ffffff !important;
}

.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active {
    background-color: var(--sps-blue-dark, #12335b) !important;
    border-color: var(--sps-blue-dark, #12335b) !important;
    color: #ffffff !important;
}

.btn-outline-primary {
    color: var(--sps-blue, #17466a) !important;
    border-color: var(--sps-blue, #17466a) !important;
    background-color: transparent !important;
}

.btn-outline-primary:hover {
    background-color: var(--sps-blue, #17466a) !important;
    color: #ffffff !important;
}

/* Page Header Banner */
.page-header-banner {
    background: linear-gradient(135deg, #17466a 0%, #12335b 100%) !important;
    padding: 46px 0 !important;
    color: #ffffff !important;
    text-align: center !important;
}

.page-header-banner h1 {
    font-size: 32px !important;
    font-weight: 800 !important;
    color: #ffffff !important;
    margin: 0 0 8px !important;
}

.page-header-banner .breadcrumbs {
    font-size: 13.5px !important;
    color: #cad8e6 !important;
}

.page-header-banner .breadcrumbs a {
    color: #38bdf8 !important;
    text-decoration: none !important;
}

.page-header-banner .breadcrumbs a:hover {
    text-decoration: underline !important;
}

/* ========================================================
   1. Global Brand Utilities & Offsets
   ======================================================== */
.sps-anchor-offset {
    position: relative;
    top: -80px;
    visibility: hidden;
    height: 0;
    margin: 0;
    padding: 0;
}

/* ========================================================
   2. Hero Section Height & Button Visibility Adjustment
   ======================================================== */
.sps-hero.sps-hero-bg-mode {
    position: relative !important;
    min-height: 480px !important;
    display: flex !important;
    align-items: center !important;
    overflow: hidden !important;
}

.sps-hero-inner {
    position: relative !important;
    z-index: 2 !important;
    min-height: 480px !important;
    display: flex !important;
    align-items: center !important;
    padding: 24px 0 !important;
    width: 100% !important;
}

.sps-hero-copy {
    max-width: 580px !important;
    padding: 10px 0 !important;
}

.sps-hero-copy h1 {
    font-size: clamp(32px, 4.2vw, 52px) !important;
    line-height: 1.05 !important;
    margin: 0 0 14px !important;
}

.sps-hero-copy p {
    font-size: clamp(14px, 1.4vw, 17px) !important;
    line-height: 1.5 !important;
    margin: 0 0 20px !important;
}

.sps-hero-actions {
    display: flex !important;
    gap: 14px !important;
    align-items: center !important;
    flex-wrap: wrap !important;
}

/* ========================================================
   3. Popular Classes Dynamic Cards
   ======================================================== */
.sps-class-card {
    border: 1px solid var(--sps-border-subtle, #dbe8f5);
    border-radius: 16px;
    overflow: hidden;
    background: #ffffff;
    box-shadow: var(--sps-shadow, 0 10px 28px rgba(22, 42, 69, 0.08));
    display: flex;
    flex-direction: column;
    padding: 16px;
    height: 100%;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.sps-class-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 16px 32px rgba(27, 69, 120, 0.12);
}

.sps-class-thumb-wrap {
    height: 200px;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 15px;
    background: #edf5fa;
}

.sps-class-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.35s ease;
}

.sps-class-card:hover .sps-class-thumb {
    transform: scale(1.05);
}

.sps-class-meta {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 10px;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.5px;
    color: var(--sps-text-muted, #4a6382);
}

.sps-class-meta span {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    text-transform: uppercase;
}

.sps-class-meta .dashicons {
    font-size: 15px;
    width: 15px;
    height: 15px;
    color: var(--theme-secondary, #4b86c4);
}

.sps-class-card h3 {
    font-size: 18px;
    font-weight: 800;
    color: var(--sps-blue-dark, #122f53);
    margin: 0 0 10px;
    line-height: 1.3;
}

.sps-class-card h3 a {
    color: inherit;
    text-decoration: none;
}

.sps-class-card h3 a:hover {
    color: var(--theme-accent, #d83f3a);
}

.sps-class-card p {
    font-size: 13.5px;
    line-height: 1.6;
    color: var(--sps-text-muted, #4a6382);
    margin-bottom: 18px;
    flex-grow: 1;
}

.sps-class-card .sps-btn {
    align-self: flex-start;
}

/* ========================================================
   4. Header, Footer & WhatsApp Chat Specifics
   ======================================================== */
.sps-header-logo-img {
    object-fit: contain;
    width: 100px;
    height: 90px;
}

.sps-footer .sps-footer-rule {
    background: #38bdf8 !important;
    width: 80px;
    height: 3px;
    border-radius: 2px;
    margin: 10px 0 18px;
}

.sps-footer .sps-contact-line .dashicons {
    color: #38bdf8 !important;
}

.sps-footer .sps-copyright strong {
    color: #38bdf8 !important;
}

.sps-footer-logo-img {
    background: #ffffff;
    border-radius: 10px;
    padding: 6px;
    width: 120px;
    height: auto;
    object-fit: contain;
}

.kmps-whatsapp-float {
    display: block;
    position: fixed;
    bottom: 20px;
    left: 20px;
    z-index: 99999;
}

.kmps-whatsapp-link {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.kmps-whatsapp-svg {
    display: block;
    height: 50px;
    width: 50px;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.25));
    transition: transform 0.2s ease;
}

.kmps-whatsapp-link:hover .kmps-whatsapp-svg {
    transform: scale(1.08);
}

/* ========================================================
   5. Facilities Archive Page
   ======================================================== */
.sps-facility-archive-card {
    padding: 24px;
    background: #ffffff;
    border: 1px solid #dce8ef;
    border-radius: 14px;
    box-shadow: 0 4px 18px rgba(13, 65, 109, 0.06);
    display: flex;
    flex-direction: column;
    height: 100%;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.sps-facility-archive-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 24px rgba(13, 65, 109, 0.12);
}

.sps-facility-archive-card .facility-thumb-wrap {
    margin-bottom: 16px;
    border-radius: 10px;
    overflow: hidden;
    height: 180px;
}

.sps-facility-archive-card .facility-thumb-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.sps-facility-archive-card .facility-fallback-icon {
    width: 64px;
    height: 64px;
    border-radius: 14px;
    background: #eaf4fc;
    color: #07558f;
    display: grid;
    place-items: center;
    margin-bottom: 16px;
}

.sps-facility-archive-card .facility-fallback-icon .dashicons {
    font-size: 32px;
    width: 32px;
    height: 32px;
}

.sps-facility-archive-card h3 {
    font-size: 18px;
    color: #0b426e;
    margin: 0 0 10px;
    font-weight: 800;
}

.sps-facility-archive-card h3 a {
    color: inherit;
    text-decoration: none;
}

.sps-facility-archive-card .facility-desc {
    color: #557288;
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 16px;
    flex-grow: 1;
}

/* ========================================================
   6. Contact Page Styles
   ======================================================== */
.sps-contact-page-area {
    padding: 55px 0 70px;
    background-color: var(--sps-bg-page, #f8fbfd);
}

.sps-contact-info-card {
    padding: 22px 24px;
    display: flex;
    gap: 18px;
    align-items: center;
    background: #ffffff;
    border-radius: 14px;
    border: 1px solid #e2edf3;
    box-shadow: 0 4px 15px rgba(13, 65, 109, 0.05);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.sps-contact-info-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 22px rgba(13, 65, 109, 0.09);
}

.sps-contact-icon-wrap {
    width: 52px;
    height: 52px;
    min-width: 52px;
    border-radius: 12px;
    display: grid;
    place-items: center;
}

.sps-contact-icon-wrap .dashicons {
    font-size: 26px;
    width: 26px;
    height: 26px;
}

.sps-contact-icon-location {
    background: #eaf4fc;
    color: #07558f;
}

.sps-contact-icon-phone {
    background: #effaf0;
    color: #1e9b4b;
}

.sps-contact-icon-email {
    background: #fff2f6;
    color: #df2f69;
}

.sps-contact-info-card h4 {
    font-size: 16px;
    color: #0b426e;
    margin: 0 0 5px;
    font-weight: 800;
}

.sps-contact-info-card p {
    font-size: 14px;
    color: #55738a;
    margin: 0;
    line-height: 1.5;
}

.sps-contact-info-card a {
    color: #07558f;
    text-decoration: none;
    font-weight: 600;
}

.sps-contact-info-card a:hover {
    text-decoration: underline;
}

.sps-contact-form-panel {
    background: #ffffff;
    padding: 36px 32px;
    border-radius: 16px;
    border: 1px solid #dce8ef;
    box-shadow: 0 8px 30px rgba(13, 65, 109, 0.08);
}

.sps-contact-form-panel h3 {
    font-size: 22px;
    color: #0b426e;
    margin: 0 0 8px;
    font-weight: 800;
}

.sps-contact-form-panel .sps-form-subtitle {
    font-size: 13.5px;
    color: #638299;
    margin: 0 0 24px;
    line-height: 1.5;
}

.sps-form-group {
    margin-bottom: 18px;
}

.sps-form-group label {
    display: block;
    font-size: 13px;
    font-weight: 700;
    color: #143e62;
    margin-bottom: 7px;
}

.sps-form-group label .req {
    color: #e63946;
    margin-left: 2px;
}

.sps-form-control {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid #cad8e0;
    border-radius: 10px;
    font-size: 14px;
    color: #1e3a52;
    background-color: #fbfdff;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.sps-form-control:focus {
    border-color: #07558f;
    background-color: #ffffff;
    box-shadow: 0 0 0 3px rgba(7, 85, 143, 0.12);
}

.sps-form-submit-btn {
    width: 100%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 28px;
    background: #17466a !important;
    color: #ffffff !important;
    border: 0;
    border-radius: 999px;
    font-size: 15px;
    font-weight: 800;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.sps-form-submit-btn:hover {
    background: #0d2f4a !important;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(23, 70, 106, 0.35);
}

.sps-form-submit-btn:active {
    transform: translateY(0);
    box-shadow: 0 3px 10px rgba(23, 70, 106, 0.2);
}

.sps-contact-alert {
    padding: 14px 18px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 22px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.sps-alert-success {
    background: #eafaf1;
    color: #0e7039;
    border: 1px solid #b7ebd0;
}

.sps-alert-error {
    background: #fdf2f2;
    color: #bc1c2c;
    border: 1px solid #f6c8c8;
}

/* ========================================================
   7. Single Post, Page & Blog Archive Styles
   ======================================================== */
.sps-article-panel {
    background: #ffffff;
    border: 1px solid #dce8ef;
    border-radius: 14px;
    padding: 30px;
    box-shadow: 0 4px 18px rgba(13, 65, 109, 0.05);
}

.sps-article-thumb {
    margin-bottom: 20px;
    border-radius: 10px;
    overflow: hidden;
    max-height: 380px;
}

.sps-article-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.sps-post-meta {
    font-size: 13px;
    color: var(--sps-text-muted, #4a6382);
    margin-bottom: 12px;
    border-bottom: 1px solid #eef3f7;
    padding-bottom: 10px;
}

.sps-sidebar-card {
    background: #ffffff;
    border: 1px solid #dce8ef;
    border-radius: 14px;
    padding: 24px;
    box-shadow: 0 4px 18px rgba(13, 65, 109, 0.05);
    margin-bottom: 24px;
}

.sps-sidebar-title {
    font-size: 18px;
    margin-bottom: 15px;
    color: var(--theme-primary, #1b4578);
    border-bottom: 2px solid var(--theme-accent, #d83f3a);
    padding-bottom: 8px;
    font-weight: 800;
}

/* ========================================================
   8. Comments & Form Styling
   ======================================================== */
.sps-comments-area ol.comment-list {
    padding-left: 0;
    list-style: none;
}

.sps-comments-area li.comment {
    background: #ffffff;
    border: 1px solid #dce8ef;
    border-radius: 14px;
    padding: 20px;
    margin-bottom: 16px;
    box-shadow: 0 4px 15px rgba(13, 65, 109, 0.04);
}

.sps-comments-area li.comment .comment-body {
    position: relative;
}

.sps-comments-area .comment-author {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
    font-weight: 700;
}

.sps-comments-area .comment-author .avatar {
    border-radius: 50%;
}

.sps-comments-area .comment-metadata {
    font-size: 12px;
    color: var(--sps-text-muted, #4a6382);
    margin-bottom: 10px;
}

.sps-comments-area .comment-metadata a {
    color: inherit;
    text-decoration: none;
}

.sps-comments-area .reply a {
    font-size: 12px;
    font-weight: 700;
    color: var(--theme-primary, #1b4578);
    text-decoration: none;
}

.sps-comments-area ul.children {
    list-style: none;
    padding-left: 24px;
    margin-top: 16px;
}

/* ========================================================
   9. About Us Page Styles
   ======================================================== */
.sps-about-badge-float {
    z-index: 2;
    transition: transform 0.25s ease;
}

.sps-about-badge-float:hover {
    transform: translateY(-3px);
}

.sps-value-box {
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.sps-value-box:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 28px rgba(18, 47, 83, 0.10) !important;
    border-color: var(--theme-secondary, #4b86c4) !important;
}
