/* Revolutionary Blocks — frontend base styles.
 * Generic structural rules. Per-post visual overrides live in
 * uploads/revblocks-css/{post-id}-{hash}.css. */

.rb-document {
    width: 100%;
}

.rb-section {
    width: 100%;
    box-sizing: border-box;
}

.rb-section__inner {
    max-width: 1140px;
    margin: 0 auto;
    padding: 40px 20px;
    display: flex;
    flex-wrap: wrap;
    box-sizing: border-box;
}

.rb-column {
    flex: 1 1 0;
    min-width: 0;
    padding: 10px;
    box-sizing: border-box;
}

.rb-widget {
    margin: 0 0 16px;
    max-width: 100%;
}

.rb-widget:last-child {
    margin-bottom: 0;
}

/* Embedded media should never bust out of its widget container, even when
 * a shortcode plugin emits a fixed-width iframe or oversized video. */
.rb-widget iframe,
.rb-widget video,
.rb-widget embed,
.rb-widget object {
    max-width: 100%;
}

/* Shortcode output (third-party sliders, videos, embeds) gets a positioning
 * context and overflow clip so absolutely-positioned children stay inside. */
.rb-widget--shortcode {
    position: relative;
    overflow: hidden;
    max-width: 100%;
}

.rb-widget--heading h1,
.rb-widget--heading h2,
.rb-widget--heading h3,
.rb-widget--heading h4,
.rb-widget--heading h5,
.rb-widget--heading h6 {
    margin: 0;
}

.rb-widget--text p {
    margin: 0 0 1em;
}

.rb-widget--button {
    display: block;
}

.rb-button {
    display: inline-block;
    padding: 12px 24px;
    border-radius: 6px;
    background: #2563eb;
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    transition: background 0.15s ease;
}

.rb-button:hover {
    background: #1d4ed8;
    color: #fff;
}

.rb-image img {
    max-width: 100%;
    height: auto;
    display: block;
}

.rb-spacer { width: 100%; }

.rb-divider {
    width: 100%;
    height: 0;
    border-top: 1px solid #e5e7eb;
}

.rb-hero {
    position: relative;
    padding: 80px 24px;
    text-align: center;
    background: #0f172a;
    color: #fff;
    border-radius: 8px;
    overflow: hidden;
}

.rb-hero h1 { font-size: 2.5rem; margin: 0 0 12px; }
.rb-hero p  { font-size: 1.125rem; margin: 0 0 24px; opacity: 0.9; }

.rb-pricing {
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 32px 24px;
    text-align: center;
    background: #fff;
}
.rb-pricing__price { font-size: 2.5rem; font-weight: 700; margin: 16px 0; }
.rb-pricing__features { list-style: none; padding: 0; margin: 16px 0; }
.rb-pricing__features li { padding: 8px 0; border-bottom: 1px solid #f1f5f9; }
.rb-pricing__features li:last-child { border-bottom: 0; }

.rb-testimonial {
    padding: 24px;
    border-left: 4px solid #2563eb;
    background: #f8fafc;
    border-radius: 4px;
}
.rb-testimonial__quote { font-style: italic; margin: 0 0 16px; }
.rb-testimonial__author { display: flex; align-items: center; gap: 12px; }
.rb-testimonial__avatar { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; }
.rb-testimonial__name { font-weight: 600; }
.rb-testimonial__role { color: #6b7280; font-size: 0.9rem; }

.rb-accordion__item { border: 1px solid #e5e7eb; border-radius: 6px; margin-bottom: 8px; overflow: hidden; }
.rb-accordion__header {
    width: 100%;
    text-align: left;
    background: #fff;
    border: 0;
    padding: 16px 20px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.rb-accordion__header::after { content: "+"; font-size: 1.25rem; }
.rb-accordion__item.is-open .rb-accordion__header::after { content: "−"; }
.rb-accordion__panel { padding: 0 20px 16px; display: none; }
.rb-accordion__item.is-open .rb-accordion__panel { display: block; }

.rb-cta {
    text-align: center;
    padding: 48px 24px;
    background: #2563eb;
    color: #fff;
    border-radius: 8px;
}
.rb-cta h2 { margin: 0 0 12px; font-size: 2rem; }
.rb-cta p  { margin: 0 0 24px; opacity: 0.9; }
.rb-cta .rb-button { background: #fff; color: #2563eb; }
.rb-cta .rb-button:hover { background: #f1f5f9; color: #1d4ed8; }

.rb-counter {
    text-align: center;
}
.rb-counter__number {
    font-size: 4rem;
    font-weight: 700;
    line-height: 1;
    color: #10b981;
    font-variant-numeric: tabular-nums;
    letter-spacing: -0.02em;
}
.rb-counter__label {
    margin-top: 8px;
    font-size: 1rem;
    color: #0f172a;
    opacity: 0.8;
}

@media (max-width: 767px) {
    .rb-section__inner { flex-direction: column; padding: 24px 16px; gap: 16px; }
    .rb-column { flex: 1 1 100% !important; max-width: 100% !important; }
    .rb-hero { padding: 48px 20px; }
    .rb-hero h1 { font-size: 1.75rem; }
    .rb-counter__number { font-size: 3rem; }
}

/* ============================================================
 * Video
 * ============================================================ */
.rb-video {
    position: relative;
    width: 100%;
    height: 0;
    overflow: hidden;
    background: #000;
    border-radius: 6px;
}
.rb-video iframe,
.rb-video video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

/* ============================================================
 * Icon
 * ============================================================ */
.rb-icon { line-height: 1; }
.rb-icon__glyph { display: inline-block; vertical-align: middle; }
.rb-icon__link { display: inline-block; text-decoration: none; }

/* ============================================================
 * Google Maps
 * ============================================================ */
.rb-map {
    position: relative;
    width: 100%;
    overflow: hidden;
    border-radius: 6px;
}
.rb-map iframe { width: 100%; height: 100%; border: 0; display: block; }

/* ============================================================
 * Tabs
 * ============================================================ */
.rb-tabs__nav {
    display: flex;
    gap: 4px;
    border-bottom: 1px solid #e5e7eb;
    margin-bottom: 16px;
    flex-wrap: wrap;
}
.rb-tabs__btn {
    background: transparent;
    border: 0;
    border-bottom: 2px solid transparent;
    padding: 10px 14px;
    font-size: 14px;
    font-weight: 500;
    color: #475569;
    cursor: pointer;
    margin-bottom: -1px;
}
.rb-tabs__btn:hover { color: #0f172a; }
.rb-tabs__btn.is-active { color: #2563eb; border-bottom-color: #2563eb; }
.rb-tabs__panel { display: none; }
.rb-tabs__panel.is-active { display: block; }

/* ============================================================
 * Image Box / Icon Box
 * ============================================================ */
.rb-imagebox img { max-width: 100%; height: auto; display: block; margin: 0 auto 12px; border-radius: 4px; }
.rb-imagebox__title,
.rb-iconbox__title { margin: 0; font-size: 1.25rem; }
.rb-imagebox__body,
.rb-iconbox__body { margin: 0; color: #475569; }
.rb-iconbox__icon { display: inline-block; }
.rb-iconbox__icon--svg svg { display: block; }
.rb-iconbox__icon-wrap { display: inline-flex; align-items: center; justify-content: center; }
.rb-iconbox__content { display: flex; flex-direction: column; }
.rb-iconbox__link { color: inherit; text-decoration: none; }

/* ============================================================
 * Icon List
 * ============================================================ */
.rb-iconlist { list-style: none; margin: 0; padding: 0; }
.rb-iconlist__item { display: flex; align-items: center; gap: 10px; padding: 6px 0; }
.rb-iconlist__item a { display: flex; align-items: center; gap: 10px; text-decoration: none; color: inherit; }
.rb-iconlist__icon { font-size: 18px; width: 18px; height: 18px; line-height: 1; }

/* ============================================================
 * Progress Bar
 * ============================================================ */
.rb-progress__head {
    display: flex;
    justify-content: space-between;
    margin-bottom: 6px;
    font-size: 13px;
    color: #0f172a;
}
.rb-progress__pct { font-weight: 600; }
.rb-progress__track {
    width: 100%;
    background: #e5e7eb;
    border-radius: 999px;
    overflow: hidden;
}
.rb-progress__fill {
    height: 100%;
    background: #3b82f6;
    border-radius: 999px;
    transition: width 0.9s ease;
}

/* ============================================================
 * Alert
 * ============================================================ */
.rb-alert {
    padding: 14px 18px;
    border-radius: 6px;
    border-left: 4px solid;
    background: #f1f5f9;
}
.rb-alert--info    { background: #eff6ff; border-color: #3b82f6; color: #1e3a8a; }
.rb-alert--success { background: #ecfdf5; border-color: #10b981; color: #065f46; }
.rb-alert--warning { background: #fffbeb; border-color: #f59e0b; color: #92400e; }
.rb-alert--danger  { background: #fef2f2; border-color: #ef4444; color: #991b1b; }
.rb-alert__title { font-weight: 700; margin-bottom: 4px; }
.rb-alert__body  { margin: 0; font-size: 14px; }
.rb-alert__body p { margin: 0 0 0.4em; }

/* ============================================================
 * Social Icons
 * ============================================================ */
.rb-social {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    align-items: center;
}
.rb-social__link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    color: #fff;
    text-decoration: none;
    transition: transform 0.12s ease, opacity 0.12s ease;
}
.rb-social__link:hover { transform: translateY(-2px); opacity: 0.9; }
.rb-social__link .dashicons { font-size: 18px; width: 18px; height: 18px; }

/* ============================================================
 * Rating
 * ============================================================ */
.rb-rating {
    position: relative;
    display: inline-block;
    line-height: 1;
}
.rb-rating__track .dashicons,
.rb-rating__fill  .dashicons { line-height: 1; }
.rb-rating__track { color: #e5e7eb; }
.rb-rating__fill  {
    color: #f59e0b;
    position: absolute;
    inset: 0;
    overflow: hidden;
    white-space: nowrap;
    pointer-events: none;
}

/* ============================================================
 * Toggle (collapsible)
 * ============================================================ */
.rb-toggle-w { border: 1px solid #e5e7eb; border-radius: 6px; overflow: hidden; }
.rb-toggle-w__head {
    width: 100%;
    text-align: left;
    background: #fff;
    border: 0;
    padding: 14px 18px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.rb-toggle-w__head::after { content: "+"; font-size: 1.25rem; }
.rb-toggle-w.is-open .rb-toggle-w__head::after { content: "−"; }
.rb-toggle-w__body { padding: 0 18px 14px; display: none; }
.rb-toggle-w.is-open .rb-toggle-w__body { display: block; }

/* ============================================================
 * Animated Headline
 * ============================================================ */
.rb-anim__cycle { position: relative; display: inline-block; min-width: 1ch; }
.rb-anim__word {
    display: inline-block;
    opacity: 0;
    transition: opacity 0.5s ease;
}
.rb-anim__word.is-active { opacity: 1; }
.rb-anim__word:not(.is-active) { position: absolute; left: 0; top: 0; }

/* ============================================================
 * Price List
 * ============================================================ */
.rb-pricelist { list-style: none; margin: 0; padding: 0; }
.rb-pricelist__item { padding: 10px 0; border-bottom: 1px dashed #e5e7eb; }
.rb-pricelist__item:last-child { border-bottom: 0; }
.rb-pricelist__head { display: flex; align-items: baseline; gap: 8px; }
.rb-pricelist__name { font-weight: 600; }
.rb-pricelist__dots { flex: 1; border-bottom: 1px dotted #cbd5e1; transform: translateY(-4px); }
.rb-pricelist__price { font-weight: 700; color: #3b82f6; }
.rb-pricelist__desc { color: #64748b; font-size: 0.9rem; margin-top: 2px; }

/* ============================================================
 * Flip Box
 * ============================================================ */
.rb-flip {
    perspective: 1200px;
    width: 100%;
    height: 280px;
}
.rb-flip__inner {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 0.7s;
    transform-style: preserve-3d;
}
.rb-flip:hover .rb-flip__inner { transform: rotateY(180deg); }
.rb-flip__face {
    position: absolute;
    inset: 0;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #fff;
    border-radius: 8px;
    padding: 24px;
}
.rb-flip__back { transform: rotateY(180deg); }
.rb-flip__face h3 { margin: 0 0 8px; font-size: 1.5rem; }
.rb-flip__face p  { margin: 0; opacity: 0.92; }

/* ============================================================
 * Countdown
 * ============================================================ */
.rb-countdown {
    display: flex;
    gap: 18px;
    justify-content: center;
    flex-wrap: wrap;
}
.rb-countdown__cell {
    min-width: 72px;
    text-align: center;
}
.rb-countdown__num {
    font-size: 2.75rem;
    font-weight: 700;
    line-height: 1;
    font-variant-numeric: tabular-nums;
}
.rb-countdown__label {
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-size: 0.75rem;
    color: #64748b;
    margin-top: 4px;
}

/* ============================================================
 * Blockquote
 * ============================================================ */
.rb-quote {
    position: relative;
    padding: 24px 24px 24px 28px;
    border-left: 4px solid #3b82f6;
    background: #f8fafc;
    border-radius: 6px;
    margin: 0;
}
.rb-quote__mark {
    position: absolute;
    top: -10px;
    left: 16px;
    font-size: 3rem;
    line-height: 1;
    color: #3b82f6;
    font-family: Georgia, serif;
}
.rb-quote__text { font-style: italic; font-size: 1.125rem; margin: 0 0 12px; }
.rb-quote__author { font-weight: 600; }
.rb-quote__role { color: #64748b; font-size: 0.875rem; }

/* ============================================================
 * Site widgets
 * ============================================================ */
.rb-sitelogo img { display: inline-block; max-width: 100%; height: auto; }
.rb-sitetitle a, .rb-pagetitle a { color: inherit; text-decoration: none; }
.rb-excerpt { color: #475569; }
.rb-crumbs { font-size: 14px; color: #475569; }
.rb-crumbs a { color: #2563eb; text-decoration: none; }
.rb-crumbs__sep { margin: 0 8px; color: #94a3b8; }

/* ============================================================
 * WordPress widgets
 * ============================================================ */
.rb-search-form { display: flex; gap: 8px; }
.rb-search-form input[type="search"] {
    flex: 1;
    padding: 10px 12px;
    border: 1px solid #cbd5e1;
    border-radius: 4px;
}
.rb-search-form button {
    padding: 0 18px;
    background: #2563eb;
    color: #fff;
    border: 0;
    border-radius: 4px;
    cursor: pointer;
}
.rb-recent { list-style: none; margin: 0; padding: 0; }
.rb-recent__item { padding: 8px 0; border-bottom: 1px solid #f1f5f9; display: flex; flex-direction: column; }
.rb-recent__item a { text-decoration: none; color: #0f172a; font-weight: 500; }
.rb-recent__item a:hover { color: #2563eb; }
.rb-recent__date { color: #94a3b8; font-size: 0.8rem; }
.rb-categories, .rb-archives { list-style: none; margin: 0; padding: 0; }
.rb-categories li, .rb-archives li { padding: 6px 0; }
.rb-categories a, .rb-archives a { color: #2563eb; text-decoration: none; }
.rb-tagcloud a {
    display: inline-block;
    padding: 4px 10px;
    margin: 2px;
    background: #f1f5f9;
    color: #475569;
    border-radius: 999px;
    text-decoration: none;
    font-size: 13px !important;
}
.rb-tagcloud a:hover { background: #2563eb; color: #fff; }
.rb-comments { list-style: none; margin: 0; padding: 0; }
.rb-comments__item { padding: 8px 0; border-bottom: 1px solid #f1f5f9; font-size: 14px; }
.rb-comments__item a { color: #2563eb; text-decoration: none; }
.rb-navmenu__list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 18px;
    flex-wrap: wrap;
}
.rb-navmenu__list--vertical { flex-direction: column; gap: 4px; }
.rb-navmenu__list a {
    color: #0f172a;
    text-decoration: none;
    padding: 6px 4px;
    display: inline-block;
}
.rb-navmenu__list a:hover { color: #2563eb; }
.rb-calendar table { width: 100%; border-collapse: collapse; }
.rb-calendar caption { font-weight: 600; padding: 8px 0; }
.rb-calendar th, .rb-calendar td { padding: 6px; text-align: center; border: 1px solid #f1f5f9; }
.rb-calendar td a { color: #2563eb; text-decoration: none; font-weight: 600; }

/* ============================================================
 * Audio
 * ============================================================ */
.rb-audio audio { width: 100%; display: block; }
.rb-audio--embed { position: relative; padding-bottom: 166px; height: 0; overflow: hidden; }
.rb-audio--embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.rb-audio--spotify { padding-bottom: 232px; }

/* ============================================================
 * Image Carousel
 * ============================================================ */
.rb-carousel {
    position: relative;
    overflow: hidden;
    background: #f1f5f9;
    border-radius: 8px;
    width: 100%;
}
.rb-carousel__track {
    position: relative;
    width: 100%;
    height: 100%;
}
.rb-carousel__slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 0.5s ease;
    pointer-events: none;
}
.rb-carousel__slide.is-active {
    opacity: 1;
    pointer-events: auto;
}
.rb-carousel__slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.rb-carousel__arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: rgba(15,23,42,0.55);
    color: #fff;
    border: 0;
    cursor: pointer;
    font-size: 24px;
    line-height: 38px;
    z-index: 2;
    transition: background 0.15s ease;
}
.rb-carousel__arrow:hover { background: rgba(15,23,42,0.85); }
.rb-carousel__arrow--prev { left: 12px; }
.rb-carousel__arrow--next { right: 12px; }
.rb-carousel__dots {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 12px;
    display: flex;
    gap: 6px;
    justify-content: center;
    z-index: 2;
}
.rb-carousel__dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255,255,255,0.55);
    border: 0;
    padding: 0;
    cursor: pointer;
    transition: background 0.15s ease, transform 0.15s ease;
}
.rb-carousel__dot.is-active {
    background: #fff;
    transform: scale(1.3);
}

/* ============================================================
 * Image Gallery
 * ============================================================ */
.rb-gallery img { transition: transform 0.3s ease; }
.rb-gallery__item:hover img { transform: scale(1.04); }

/* ============================================================
 * Menu Anchor / Read More
 * ============================================================ */
.rb-anchor { display: block; height: 0; overflow: hidden; }
.rb-anchor__label {
    display: inline-block;
    background: #eef2ff;
    color: #4338ca;
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 999px;
}
.revblocks-active .rb-anchor__label { display: none; }
.rb-anchor--placeholder {
    height: auto;
    border: 1px dashed #cbd5e1;
    color: #64748b;
    padding: 10px;
    border-radius: 4px;
    text-align: center;
    font-size: 13px;
}
.rb-readmore {
    display: inline-block;
    color: #2563eb;
    font-weight: 600;
    text-decoration: none;
}
.rb-readmore:hover { text-decoration: underline; }
.rb-readmore--inline {
    color: #94a3b8;
    text-align: center;
    font-style: italic;
    padding: 12px 0;
    border-top: 1px dashed #e5e7eb;
    border-bottom: 1px dashed #e5e7eb;
}

/* ============================================================
 * Sidebar / WP widget bridge
 * ============================================================ */
.rb-sidebar .widget,
.rb-wpwidget { margin-bottom: 18px; }
.rb-wpwidget__title { margin: 0 0 10px; font-size: 1.1rem; }
