/* Show Page - About Tab Styles - Updated: 2025-11-14 */

/* ================================================
   BOOK ONLINE NUDGE
   ================================================ */

.book-online-nudge {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem 1.25rem;
    background: linear-gradient(135deg, var(--htt-accent-soft) 0%, var(--htt-accent-soft) 100%);
    border-left: 4px solid var(--htt-accent);
    border-radius: 0.5rem;
    margin-top: 1.5rem;
}

.nudge-icon {
    width: 1.25rem;
    height: 1.25rem;
    color: var(--htt-accent);
    flex-shrink: 0;
    margin-top: 0.125rem;
}

.book-online-nudge p {
    margin: 0;
    color: #4b5563;
    font-size: 0.9375rem;
    line-height: 1.6;
}

.book-online-nudge strong {
    color: var(--htt-accent);
    font-weight: 600;
}

/* ================================================
   VIDEO SECTION
   ================================================ */

.video-section {
    margin-bottom: 2.5rem;
}

.video-transcript-link {
    display: inline-flex;
    align-items: center;
    margin-top: 0.75rem;
    color: var(--htt-accent);
    font-size: 0.875rem;
    font-weight: 500;
    text-decoration: none;
    transition: color 0.2s;
}

.video-transcript-link:hover {
    color: var(--htt-accent-hover);
    text-decoration: underline;
}

/* ================================================
   THEMES & TAGS
   ================================================ */

.theme-tag-link {
    text-decoration: none;
    transition: all 0.2s;
}

.theme-tag-link:hover {
    background-color: var(--htt-accent);
    color: white;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(122, 31, 43, 0.2);
}

/* ================================================
   FAQ ACCORDION (NEW BUTTON-BASED)
   ================================================ */

.faqs-section {
    margin-top: 2.5rem;
}

.faqs-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.faq-controls {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.faq-control-btn {
    background: none;
    border: none;
    color: var(--htt-accent);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    padding: 0.25rem 0.5rem;
    transition: all 0.2s;
}

.faq-control-btn:hover {
    color: var(--htt-accent-hover);
    text-decoration: underline;
}

.faq-control-btn:focus {
    outline: 2px solid var(--htt-accent);
    outline-offset: 2px;
    border-radius: 0.25rem;
}

.faq-control-separator {
    color: #d1d5db;
}

.faqs-container {
    border-top: 1px solid #e5e7eb;
}

.faq-item {
    border-bottom: 1px solid #e5e7eb;
}

.faq-question-heading {
    margin: 0;
}

.faq-toggle-btn {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem 1rem 1.25rem 0;
    background: none;
    border: none;
    cursor: pointer;
    text-align: left;
    transition: all 0.2s;
}

.faq-toggle-btn:hover {
    background-color: #fafafa;
    padding-left: 0.5rem;
}

.faq-toggle-btn:focus {
    outline: 2px solid var(--htt-accent);
    outline-offset: -2px;
    background-color: var(--htt-accent-soft);
}

.faq-question-text {
    flex: 1;
    font-size: 1.0625rem;
    font-weight: 600;
    color: #111827;
    line-height: 1.5;
    padding-right: 1rem;
}

.faq-toggle-btn .faq-icon {
    width: 1.25rem;
    height: 1.25rem;
    color: var(--htt-muted);
    flex-shrink: 0;
    transition: transform 0.3s ease;
    transform: rotate(0deg);
}

.faq-toggle-btn[aria-expanded="true"] .faq-icon {
    transform: rotate(180deg);
}

.faq-answer {
    overflow: hidden;
    max-height: 0;
    transition: max-height 0.3s ease;
}

.faq-answer[hidden] {
    display: block !important; /* Keep in DOM for SEO */
    visibility: hidden;
}

.faq-answer:not([hidden]) {
    visibility: visible;
}

.faq-answer-content {
    padding: 0 0 1.25rem 0;
    color: #4b5563;
    font-size: 0.9375rem;
    line-height: 1.7;
}

.faq-answer-content p {
    margin-bottom: 0.75rem;
}

.faq-answer-content p:last-child {
    margin-bottom: 0;
}

.faq-answer-content ul,
.faq-answer-content ol {
    margin-left: 1.5rem;
    margin-bottom: 0.75rem;
}

.faq-answer-content li {
    margin-bottom: 0.375rem;
}

.faq-answer-content a {
    color: var(--htt-accent);
    text-decoration: underline;
}

.faq-answer-content a:hover {
    color: var(--htt-accent-hover);
}

/* ================================================
   GALLERY ENHANCEMENTS
   ================================================ */

.gallery-section {
    margin-top: 2.5rem;
}

.gallery-item {
    position: relative;
    cursor: pointer;
    overflow: hidden;
}

.gallery-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s;
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}

.gallery-zoom-icon {
    width: 3rem;
    height: 3rem;
    color: white;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

/* Gallery Caption Enhancement */
.gallery-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8), transparent);
    color: white;
    padding: 1.5rem 0.75rem 0.75rem;
    font-size: 0.875rem;
    transform: translateY(100%);
    transition: transform 0.3s;
}

.gallery-item:hover .gallery-caption {
    transform: translateY(0);
}

/* ================================================
   GALLERY LIGHTBOX
   ================================================ */

.gallery-lightbox {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.95);
    animation: fadeIn 0.3s ease;
}

.lightbox-content {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    animation: zoomIn 0.3s ease;
}

.lightbox-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 3rem;
    height: 3rem;
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    z-index: 10;
}

.lightbox-close:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: rotate(90deg);
}

.lightbox-close svg {
    width: 1.5rem;
    height: 1.5rem;
}

.lightbox-prev,
.lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 3rem;
    height: 3rem;
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    z-index: 10;
}

.lightbox-prev {
    left: 2rem;
}

.lightbox-next {
    right: 2rem;
}

.lightbox-prev:hover,
.lightbox-next:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-50%) scale(1.1);
}

.lightbox-prev:disabled,
.lightbox-next:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.lightbox-prev svg,
.lightbox-next svg {
    width: 1.5rem;
    height: 1.5rem;
}

.lightbox-image-container {
    max-width: 90%;
    max-height: 90%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.lightbox-image {
    max-width: 100%;
    max-height: calc(90vh - 8rem);
    object-fit: contain;
    border-radius: 0.5rem;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.lightbox-caption,
.lightbox-credit {
    color: white;
    text-align: center;
    margin-top: 1rem;
    font-size: 0.9375rem;
}

.lightbox-caption {
    font-weight: 500;
}

.lightbox-credit {
    font-size: 0.875rem;
    opacity: 0.8;
}

.lightbox-counter {
    position: absolute;
    top: 1rem;
    left: 50%;
    transform: translateX(-50%);
    color: white;
    font-size: 0.875rem;
    font-weight: 500;
    background: rgba(0, 0, 0, 0.5);
    padding: 0.5rem 1rem;
    border-radius: 1rem;
}

/* ================================================
   ANIMATIONS
   ================================================ */

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes zoomIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* ================================================
   RESPONSIVE ADJUSTMENTS
   ================================================ */

@media (max-width: 768px) {
    .faqs-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
    }
    
    .faq-controls {
        width: 100%;
        justify-content: flex-end;
    }
    
    .faq-question-text {
        font-size: 1rem;
    }
    
    .lightbox-content {
        padding: 1rem;
    }
    
    .lightbox-prev,
    .lightbox-next {
        width: 2.5rem;
        height: 2.5rem;
    }
    
    .lightbox-prev {
        left: 1rem;
    }
    
    .lightbox-next {
        right: 1rem;
    }
    
    .lightbox-close {
        top: 0.5rem;
        right: 0.5rem;
    }
    
    .lightbox-counter {
        top: 0.5rem;
        font-size: 0.8125rem;
        padding: 0.375rem 0.75rem;
    }
    
    .book-online-nudge {
        flex-direction: column;
        gap: 0.5rem;
        padding: 1rem;
    }
}

/* ================================================
   ACCESSIBILITY
   ================================================ */

/* Screen reader only content */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .faq-toggle-btn:focus {
        outline: 3px solid currentColor;
    }
    
    .theme-tag-link:hover {
        outline: 2px solid currentColor;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    .faq-toggle-btn .faq-icon,
    .faq-answer,
    .gallery-overlay,
    .gallery-caption,
    .lightbox-overlay,
    .lightbox-content {
        transition: none;
    }
}

/* Focus visible (keyboard navigation) */
.faq-toggle-btn:focus-visible,
.faq-control-btn:focus-visible,
.lightbox-close:focus-visible,
.lightbox-prev:focus-visible,
.lightbox-next:focus-visible {
    outline: 3px solid var(--htt-accent);
    outline-offset: 2px;
}

/* ================================================
   TAB SECTION TITLE STYLING - MAXIMUM SPECIFICITY
   ================================================ */

/* Use maximum specificity to override show-tabs.css */
html body .tab-content-wrapper .tab-section .tab-section-title,
html body .show-tab-panel .tab-content-wrapper .tab-section .tab-section-title,
.tab-content-wrapper .tab-section .tab-section-title,
.tab-section .tab-section-title,
.tab-section-title {
    font-size: 1.5rem !important;
    font-weight: 700 !important;
    color: #111827 !important;
    margin-bottom: 1.25rem !important;
    line-height: 1.3 !important;
    margin-top: 0 !important;
}

/* ================================================
   WYSIWYG EDITOR TYPOGRAPHY & HEADINGS
   ================================================ */

.tab-rich-content {
    font-size: var(--htt-size-body);
    line-height: var(--htt-lh-body);
    color: #374151;
}

.tab-rich-content p {
    margin-bottom: 1rem;
}

.tab-rich-content h1,
.tab-rich-content h2,
.tab-rich-content h3,
.tab-rich-content h4,
.tab-rich-content h5,
.tab-rich-content * h1,
.tab-rich-content * h2,
.tab-rich-content * h3,
.tab-rich-content * h4,
.tab-rich-content * h5 {
    font-weight: 700 !important;
    color: #111827 !important;
    margin-top: 1.5rem !important;
    margin-bottom: 0.75rem !important;
    line-height: 1.3 !important;
}

.tab-rich-content h1,
.tab-rich-content * h1 {
    font-size: 2rem !important;
    margin-top: 0 !important;
}

/* Maximum specificity for h2 inside tab-rich-content */
html body .tab-content-wrapper .tab-section .tab-rich-content h2,
html body .tab-content-wrapper .tab-section .tab-rich-content * h2,
html body .show-tab-panel .tab-content-wrapper .tab-section .tab-rich-content h2,
html body .show-tab-panel .tab-content-wrapper .tab-section .tab-rich-content * h2,
.tab-content-wrapper .tab-section .tab-rich-content h2,
.tab-content-wrapper .tab-section .tab-rich-content * h2,
.tab-section .tab-rich-content h2,
.tab-section .tab-rich-content * h2,
.tab-rich-content h2,
.tab-rich-content * h2 {
    font-size: 1.75rem !important;
    font-weight: 700 !important;
    color: #111827 !important;
    margin-top: 1.5rem !important;
    margin-bottom: 0.75rem !important;
    line-height: 1.3 !important;
}

.tab-rich-content h3,
.tab-rich-content * h3 {
    font-size: 1.5rem !important;
}

.tab-rich-content h4,
.tab-rich-content * h4 {
    font-size: 1.25rem !important;
    font-weight: 600 !important;
}

.tab-rich-content h5,
.tab-rich-content * h5 {
    font-size: 1.125rem !important;
    font-weight: 600 !important;
}

.tab-rich-content strong,
.tab-rich-content b,
.tab-rich-content * strong,
.tab-rich-content * b {
    font-weight: 700 !important;
    color: #111827 !important;
}

.tab-rich-content em,
.tab-rich-content i,
.tab-rich-content * em,
.tab-rich-content * i {
    font-style: italic !important;
}

.tab-rich-content u,
.tab-rich-content * u {
    text-decoration: underline !important;
}

.tab-rich-content s,
.tab-rich-content del,
.tab-rich-content * s,
.tab-rich-content * del {
    text-decoration: line-through !important;
}

.tab-rich-content a,
.tab-rich-content * a {
    color: var(--htt-accent) !important;
    text-decoration: underline !important;
}

.tab-rich-content a:hover,
.tab-rich-content * a:hover {
    color: var(--htt-accent-hover) !important;
}

.tab-rich-content ul,
.tab-rich-content ol,
.tab-rich-content * ul,
.tab-rich-content * ol {
    margin-left: 1.5rem !important;
    margin-bottom: 1rem !important;
    padding-left: 0.5rem !important;
}

.tab-rich-content li,
.tab-rich-content * li {
    margin-bottom: 0.5rem !important;
}

.tab-rich-content img,
.tab-rich-content * img {
    max-width: 100% !important;
    height: auto !important;
    margin: 1.5rem 0 !important;
    border-radius: 0.5rem !important;
}

/* ================================================
   WYSIWYG EDITOR IMAGE ALIGNMENT & STYLING
   ================================================ */

/* Figure wrapper styling for images from WYSIWYG editor */
.tab-rich-content figure.image-wrapper {
    position: relative;
    display: block;
    max-width: 100%;
    margin: 1.5em 0;
    clear: both;
}

/* Image alignment styles */
.tab-rich-content figure.image-wrapper.image-align-left {
    float: left;
    margin-right: 1.5em;
    margin-left: 0;
    margin-top: 0.5em;
    margin-bottom: 0.5em;
    max-width: 50%;
}

.tab-rich-content figure.image-wrapper.image-align-center {
    display: block;
    margin-left: auto;
    margin-right: auto;
    float: none;
    text-align: center;
}

.tab-rich-content figure.image-wrapper.image-align-right {
    float: right;
    margin-left: 1.5em;
    margin-right: 0;
    margin-top: 0.5em;
    margin-bottom: 0.5em;
    max-width: 50%;
}

.tab-rich-content figure.image-wrapper.image-align-full {
    display: block;
    width: 100%;
    float: none;
    margin-left: 0;
    margin-right: 0;
}

/* Image size presets */
.tab-rich-content figure.image-wrapper.image-size-thumbnail img {
    max-width: 150px !important;
    width: auto;
    height: auto;
}

.tab-rich-content figure.image-wrapper.image-size-medium img {
    max-width: 300px !important;
    width: auto;
    height: auto;
}

.tab-rich-content figure.image-wrapper.image-size-large img {
    max-width: 600px !important;
    width: auto;
    height: auto;
}

.tab-rich-content figure.image-wrapper.image-size-full img {
    max-width: 100% !important;
    width: auto;
    height: auto;
}

/* Image styling within figure */
.tab-rich-content figure.image-wrapper img {
    max-width: 100%;
    height: auto;
    display: block;
    border-radius: 0.5rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* Caption styling */
.tab-rich-content figure.image-wrapper figcaption {
    font-size: 0.875em;
    font-style: italic;
    color: var(--htt-muted);
    text-align: center;
    margin-top: 0.5em;
    padding: 0.25em 0;
    line-height: 1.4;
}

/* Linked image indicator */
.tab-rich-content figure.image-wrapper a {
    display: block;
    position: relative;
}

.tab-rich-content figure.image-wrapper a::after {
    content: '🔗';
    position: absolute;
    top: 8px;
    right: 8px;
    background: rgba(0, 0, 0, 0.6);
    color: white;
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 10px;
    opacity: 0;
    transition: opacity 0.2s;
    pointer-events: none;
}

.tab-rich-content figure.image-wrapper:hover a::after {
    opacity: 1;
}

/* Clear floats after aligned images */
.tab-rich-content::after {
    content: "";
    display: table;
    clear: both;
}

/* Responsive adjustments for image alignment */
@media (max-width: 768px) {
    .tab-rich-content figure.image-wrapper.image-align-left,
    .tab-rich-content figure.image-wrapper.image-align-right {
        float: none;
        display: block;
        margin-left: auto;
        margin-right: auto;
        max-width: 100%;
    }
}

