﻿/* portal-base.css — base styles for portal public pages
   Customer branding goes in their CustomCSS setting file
   Class naming: portal-card--document, portal-card--event etc */

*, *::before, *::after {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;
    font-family: system-ui, -apple-system, sans-serif;
    background: transparent;
}

html body.portal-iframe,
html.portal-iframe-html {
    height: auto !important;
    overflow: visible !important;
}

/* ── List wrapper ─────────────────────────────────────── */
.portal-list {
    max-width: 1024px;
    margin: 0 auto;
}

/* ── Card Grid ─────────────────────────────────────────── */
.portal-card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 3rem;
    padding: 1.5rem;
    max-width: 1024px;
    margin: 0 auto;
}

/* ── Card ──────────────────────────────────────────────── */
.portal-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background: #fff;
}

.portal-card__image img {
    width: 100%;
    display: block;
    object-fit: cover;
}

.portal-card__body {
    padding: 1rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.portal-card__title {
    font-size: 1rem;
    font-weight: 700;
    margin: 0 0 0.5rem;
    line-height: 1.3;
}

.portal-card__date {
    font-size: 0.875rem;
    color: #666;
    margin: auto 0 0;
}

.portal-card__footer {
    padding: 0.75rem 1rem;
    margin-top: auto;
}

.portal-card__readmore {
    font-size: 0.875rem;
    text-decoration: none;
    color: inherit;
}

    .portal-card__readmore:hover {
        text-decoration: underline;
    }

/* ── Detail ────────────────────────────────────────────── */
.portal-detail {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    padding: 2rem;
    align-items: start;
    max-width: 1180px;
    margin: 0 auto;
}

@media (max-width: 640px) {
    .portal-detail {
        grid-template-columns: 1fr;
    }
}

.portal-detail__image {
    width: 350px;
}

.portal-detail__content {
    width: 700px;
}

.portal-detail__image img {
    width: 100%;
    display: block;
}

.portal-detail__date {
    font-size: 0.875rem;
    color: #666;
    margin: 0 0 0.5rem;
}

.portal-detail__title {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 0 1rem;
    line-height: 1.3;
}

.portal-detail__description {
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.portal-detail__cta {
    margin-top: 1rem;
}

/* ── Buttons ───────────────────────────────────────────── */
.portal-btn {
    display: inline-block;
    padding: 0.6rem 1.4rem;
    border: 2px solid currentColor;
    border-radius: 3px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    background: transparent;
}

/* ── States ────────────────────────────────────────────── */
.portal-loading {
    display: flex;
    justify-content: center;
    padding: 3rem;
}

.portal-spinner {
    width: 2rem;
    height: 2rem;
    border: 3px solid #e0e0e0;
    border-top-color: #333;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.portal-error,
.portal-empty {
    padding: 2rem;
    text-align: center;
    color: #666;
}

.portal-detail__categories {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1rem;
}

.portal-tag {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 3px;
    font-size: 0.8rem;
    font-weight: 500;
    background: #e0e0e0;
    color: #333;
}

/* ── Booking ───────────────────────────────────────────── */
.portal-booking {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    padding: 2rem;
    max-width: 1024px;
    margin: 0 auto;
}

@media (max-width: 640px) {
    .portal-booking {
        grid-template-columns: 1fr;
    }
}

.portal-booking__image img {
    width: 100%;
    border-radius: 4px;
}

.portal-booking__title {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 0 0.5rem;
}

.portal-booking__date, .portal-booking__location {
    font-size: 0.875rem;
    color: #666;
    margin: 0 0 0.25rem;
}

.portal-booking__form {
    margin-top: 1.5rem;
}

.portal-booking__form-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0 0 1rem;
}

.portal-booking__cta {
    margin-top: 1.5rem;
}

/* ── Form Fields ───────────────────────────────────────── */
.portal-field {
    margin-bottom: 1rem;
}

.portal-field__label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 0.25rem;
    color: #555;
}

.portal-field__input {
    width: 100%;
    padding: 0.5rem 0.75rem;
    border: 1px solid #ccc;
    border-radius: 3px;
    font-size: 0.9rem;
}

    .portal-field__input:focus {
        border-color: #4fc3d4;
        outline: none;
        box-shadow: 0 0 0 2px rgba(79,195,212,0.15);
    }

/* ── Confirmation ──────────────────────────────────────── */
.portal-booking-confirmation {
    padding: 3rem 2rem;
    text-align: center;image-orientation already have poratl
    max-width: 600px;
    margin: 0 auto;
}

    .portal-booking-confirmation h2 {
        font-size: 1.5rem;
        font-weight: 700;
        margin-bottom: 1rem;
    }
