/**
 * Tour Categories Taxonomy - Professional Styles
 * Mirrors Tour Types design with rtc- prefix
 * Uses Elementor Global Colors and Fonts
 *
 * @package RoamEase_Pro
 * @since 2.6.0
 */

/* ==========================================================================
   Container
   ========================================================================== */
.roamease-pro-tour-category-archive {
    background: var(--e-global-color-f9fafb, #f9fafb);
    min-height: 100vh;
    padding: 0 0 60px;
    overflow-x: hidden;
}

.roamease-pro-tour-category-archive > .container {
    max-width: 100%;
    width: 100%;
    padding-left: clamp(16px, 4vw, 60px);
    padding-right: clamp(16px, 4vw, 60px);
    margin: 0 auto;
    box-sizing: border-box;
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.rtc-hero {
    position: relative;
    height: 100vh;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--e-global-color-primary, #083321);
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    overflow: hidden;
    border-radius: 0;
    margin-bottom: 40px;
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
    width: 100vw;
}

.rtc-hero__overlay {
    position: absolute;
    inset: 0;
    background: transparent;
    z-index: 1;
}

.rtc-hero[style*="background-image"] .rtc-hero__overlay {
    background: rgba(0, 0, 0, 0.45);
}

.rtc-hero__content {
    position: relative;
    z-index: 2;
    width: 100%;
    padding: 80px 20px 100px;
}

.rtc-hero__container {
    max-width: 900px;
    margin: 0 auto;
    text-align: center;
}

.rtc-hero__title {
    font-size: clamp(2.2rem, 5vw, 3.5rem);
    font-weight: 400;
    color: #fff;
    margin: 0 0 30px;
    line-height: 1.2;
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
    font-family: var(--e-global-typography-primary-font-family, inherit);
}

.rtc-hero__title .type-suffix {
    font-weight: 400;
    opacity: 0.9;
}

/* Start Planning Button */
.rtc-hero__button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 16px 40px;
    background: var(--e-global-color-primary, #083321);
    color: #fff;
    font-size: 0.95rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    text-decoration: none;
    border-radius: 50px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px rgba(8, 51, 33, 0.4);
    font-family: var(--e-global-typography-secondary-font-family, inherit);
}

.rtc-hero__button:hover {
    background: var(--e-global-color-secondary, #FEBC11);
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(254, 188, 17, 0.5);
}

/* Breadcrumb inside hero */
.rtc-hero__breadcrumb {
    position: absolute;
    bottom: 20px;
    left: 0;
    right: 0;
    z-index: 3;
    padding: 0 clamp(16px, 4vw, 60px);
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.85);
    font-family: var(--e-global-typography-text-font-family, inherit);
}

.rtc-hero__breadcrumb a {
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    transition: color 0.2s ease;
}

.rtc-hero__breadcrumb a:hover {
    color: #fff;
}

.rtc-hero__breadcrumb .separator {
    opacity: 0.6;
}

.rtc-hero__breadcrumb .current {
    font-weight: 600;
    color: #fff;
}

/* ==========================================================================
   Description Section
   ========================================================================== */
.rtc-description {
    text-align: center;
    margin-bottom: 50px;
}

.rtc-description__content {
    max-width: 920px;
    margin: 0 auto;
    text-align: left;
    font-size: 1rem;
    line-height: 1.7;
    color: #4b5563;
    max-height: 320px;
    overflow: hidden;
    transition: max-height 0.4s ease;
    font-family: var(--e-global-typography-text-font-family, inherit);
}

.rtc-description__content.is-expanded {
    max-height: none;
}

.rtc-description__content p {
    margin: 0 0 1em;
}

.rtc-description__toggle {
    display: inline-block;
    margin-top: 16px;
    padding: 8px 20px;
    background: transparent;
    border: none;
    color: var(--e-global-color-primary, #083321);
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    font-family: var(--e-global-typography-text-font-family, inherit);
    transition: color 0.2s ease;
}

.rtc-description__toggle:hover {
    color: var(--e-global-color-secondary, #FEBC11);
}

/* ==========================================================================
   Tours Section
   ========================================================================== */
.rtc-tours {
    margin-bottom: 50px;
}

.rtc-tours__header {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    margin-bottom: 32px;
    padding-bottom: 0;
    border-bottom: none;
    gap: 16px;
}

.rtc-tours__title {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--e-global-color-primary, #083321);
    margin: 0;
    font-family: var(--e-global-typography-primary-font-family, inherit);
}

.rtc-tours__count {
    display: inline-flex;
    align-items: center;
    padding: 8px 20px;
    border: 2px solid var(--e-global-color-primary, #083321);
    border-radius: 50px;
    font-size: 0.95rem;
    color: var(--e-global-color-primary, #083321);
    font-family: var(--e-global-typography-text-font-family, inherit);
    background: transparent;
}

/* ==========================================================================
   Tour Cards Grid
   ========================================================================== */
.rtc-grid {
    display: grid;
    grid-template-columns: repeat(3, 360px);
    gap: 28px;
    justify-content: center;
}

@media (min-width: 1620px) {
    .rtc-grid {
        grid-template-columns: repeat(4, 360px);
    }
}

@media (max-width: 1219px) {
    .rtc-grid {
        grid-template-columns: repeat(2, 360px);
    }
}

@media (max-width: 819px) {
    .rtc-grid {
        grid-template-columns: 1fr;
    }
}

/* Card Styling */
.rtc-card {
    position: relative;
    display: flex;
    flex-direction: column;
    width: 360px;
    max-width: 100%;
    overflow: hidden;
    background: var(--e-global-color-ffffff, #ffffff);
    border-radius: 20px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid rgba(0, 0, 0, 0.04);
}

@media (max-width: 819px) {
    .rtc-card {
        width: 100%;
        max-width: 100%;
    }
}

.rtc-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.12);
}

/* Card Image */
.rtc-card__image {
    position: relative;
    aspect-ratio: 16/10;
    overflow: hidden;
}

.rtc-card__image a {
    display: block;
    width: 100%;
    height: 100%;
}

.rtc-card__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.rtc-card:hover .rtc-card__image img {
    transform: scale(1.08);
}

.rtc-card__placeholder {
    width: 100%;
    height: 100%;
    background: #e5e7eb;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    opacity: 0.5;
}

/* Card Badge */
.rtc-card__badge {
    position: absolute;
    top: 16px;
    right: 16px;
    background: var(--e-global-color-primary, #083321);
    color: var(--e-global-color-secondary, #FEBC11);
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-family: var(--e-global-typography-secondary-font-family, inherit);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Card Content */
.rtc-card__content {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding: 24px;
}

.rtc-card__title {
    font-size: 1.25rem;
    font-weight: 700;
    line-height: 1.3;
    margin: 0 0 12px;
    font-family: var(--e-global-typography-primary-font-family, inherit);
}

.rtc-card__title a {
    color: var(--e-global-color-primary, #083321);
    text-decoration: none;
    transition: color 0.2s ease;
}

/* Card Meta */
.rtc-card__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 16px;
}

.rtc-card__pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(8, 51, 33, 0.08);
    color: var(--e-global-color-primary, #083321);
    padding: 6px 14px;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 500;
    font-family: var(--e-global-typography-text-font-family, inherit);
}

/* Card Excerpt */
.rtc-card__excerpt {
    font-size: 0.95rem;
    line-height: 1.6;
    color: #6b7280;
    margin: 0 0 20px;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-family: var(--e-global-typography-text-font-family, inherit);
}

/* Card Footer */
.rtc-card__footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
    padding-top: 16px;
    border-top: 1px solid rgba(0, 0, 0, 0.06);
}

.rtc-card__price {
    display: flex;
    flex-direction: column;
}

.rtc-card__price-label {
    font-size: 0.75rem;
    color: #9ca3af;
    font-family: var(--e-global-typography-text-font-family, inherit);
}

.rtc-card__price-amount {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--e-global-color-primary, #083321);
    font-family: var(--e-global-typography-primary-font-family, inherit);
}

/* Card CTA Button */
.rtc-card__cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    background: var(--e-global-color-primary, #083321);
    color: var(--e-global-color-secondary, #FEBC11);
    border-radius: 10px;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-decoration: none;
    transition: all 0.2s ease;
    font-family: var(--e-global-typography-secondary-font-family, inherit);
}

.rtc-card:hover .rtc-card__cta {
    background: var(--e-global-color-secondary, #FEBC11);
    color: var(--e-global-color-primary, #083321);
}

/* ==========================================================================
   No Tours Found
   ========================================================================== */
.rtc-empty {
    text-align: center;
    padding: 80px 20px;
    background: var(--e-global-color-ffffff, #ffffff);
    border-radius: 20px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
}

.rtc-empty__icon {
    font-size: 4rem;
    margin-bottom: 24px;
    opacity: 0.6;
}

.rtc-empty__title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--e-global-color-primary, #083321);
    margin: 0 0 12px;
    font-family: var(--e-global-typography-primary-font-family, inherit);
}

.rtc-empty__text {
    font-size: 1rem;
    color: #6b7280;
    margin: 0 0 28px;
    font-family: var(--e-global-typography-text-font-family, inherit);
}

.rtc-empty__cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 32px;
    background: var(--e-global-color-primary, #083321);
    color: var(--e-global-color-secondary, #FEBC11);
    border-radius: 12px;
    font-size: 0.95rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-decoration: none;
    transition: all 0.2s ease;
    font-family: var(--e-global-typography-secondary-font-family, inherit);
}

.rtc-empty__cta:hover {
    background: var(--e-global-color-secondary, #FEBC11);
    color: var(--e-global-color-primary, #083321);
}

/* ==========================================================================
   Related Tour Categories - Responsive Grid
   ========================================================================== */
.rtc-related {
    text-align: center;
    padding: 60px 0 0;
    border-top: none;
    position: relative;
}

.rtc-related__title {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--e-global-color-primary, #083321);
    margin: 0 0 40px;
    font-family: var(--e-global-typography-primary-font-family, inherit);
}

/* Grid: same 4/3/2/1 pattern */
.rtc-related__grid.re-grid-4321 {
    display: grid;
    justify-items: center;
    justify-content: center;
    grid-template-columns: repeat(3, 360px);
    gap: 20px;
    padding: 10px 0 30px;
}

@media (min-width: 1620px) {
    .rtc-related__grid.re-grid-4321 {
        grid-template-columns: repeat(4, 360px);
    }
}

@media (max-width: 1219px) {
    .rtc-related__grid.re-grid-4321 {
        grid-template-columns: repeat(2, 360px);
        gap: 18px;
    }
}

@media (max-width: 819px) {
    .rtc-related__grid.re-grid-4321 {
        grid-template-columns: 1fr;
        justify-items: stretch;
        gap: 16px;
    }
}

/* Related Category Card - Fixed 360x520 overlay style */
.rtc-related__card {
    position: relative;
    display: block;
    width: 360px;
    max-width: 100%;
    height: 520px;
    border-radius: 12px;
    overflow: hidden;
    background: #000;
    text-decoration: none;
    transition: transform 0.3s ease;
}

.rtc-related__card:hover {
    transform: translateY(-6px);
}

.rtc-related__card-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.rtc-related__card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.rtc-related__card:hover .rtc-related__card-image img {
    transform: scale(1.08);
}

.rtc-related__card-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4rem;
    opacity: 0.4;
    background: #222222;
}

/* Scrim Overlay */
.rtc-related__card-scrim {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    z-index: 1;
}

/* Card Overlay Content */
.rtc-related__card-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 28px 24px 32px;
    text-align: center;
    z-index: 2;
}

/* Top Section - Tours Count Pill */
.rtc-related__card-top {
    display: flex;
    justify-content: center;
}

.rtc-related__card-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 20px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.9);
    background: rgba(0, 0, 0, 0.06);
    color: #ffffff;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    font-family: var(--e-global-typography-secondary-font-family, inherit);
}

/* Main Section - Title and Description */
.rtc-related__card-main {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 20px;
}

.rtc-related__card-title {
    font-size: clamp(22px, 2.4vw, 28px);
    font-weight: 700;
    font-style: normal;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #ffffff;
    margin: 0 0 14px;
    line-height: 1.2;
    font-family: var(--e-global-typography-primary-font-family, 'Playfair Display', Georgia, serif);
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.rtc-related__card-desc {
    font-size: 14px;
    line-height: 1.65;
    color: #f9fafb;
    margin: 0;
    max-width: 300px;
    font-family: var(--e-global-typography-text-font-family, inherit);
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Responsive: Mobile card full width */
@media (max-width: 819px) {
    .rtc-related__card {
        width: 100%;
        max-width: 100%;
        height: auto;
        min-height: 420px;
    }
}

/* ==========================================================================
   Responsive Adjustments
   ========================================================================== */
@media (max-width: 768px) {
    .rtc-hero {
        min-height: 320px;
        border-radius: 16px;
    }

    .rtc-hero__content {
        padding: 40px 16px;
    }

    .rtc-tours__header {
        flex-direction: column;
        text-align: center;
        gap: 12px;
    }

    .rtc-card__footer {
        flex-direction: column;
        gap: 16px;
        align-items: stretch;
    }

    .rtc-card__price {
        text-align: center;
    }

    .rtc-card__cta {
        width: 100%;
    }
}
