@import url("/_content/OqtaneLibrary.Components/wallet-balance.css");

/* SpeechHandling-modul */
.speech-module {
    box-sizing: border-box;
    width: 100vw;
    max-width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    padding: 0 0 2rem;
    background: transparent;
}

/* Landing – Oqtane-tema utenfor, grått lag, hero og SiteSettings (som MatchMate) */
.speech-module.speech-module--landing {
    --speech-gutter: 0.5rem;
    --speech-landing-inset: 0.5rem;
    --speech-landing-bg: #e4e7eb;
    --speech-panel-bg: #eceff1;
    --speech-panel-border: #cfd3d8;
    --speech-card-bg: #fff;
    --ks-accent: var(--tts-accent, #673ab7);
    --ks-accent-deep: var(--tts-accent-deep, #311b92);
    --ks-border: #dadce0;
    --ks-bg: var(--speech-landing-bg);
    --ks-panel-bg: var(--speech-panel-bg);
    --ks-panel-border: var(--speech-panel-border);
    --ks-card-bg: var(--speech-card-bg);
    --ks-text: #202124;
    --ks-text-secondary: #3c4043;
    --ks-text-muted: #5f6368;
    box-sizing: border-box;
    width: 100vw;
    max-width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    padding: var(--speech-landing-inset);
    padding-bottom: 2rem;
    min-height: 1px;
    overflow-x: clip;
    display: flex;
    flex-direction: column;
    gap: var(--speech-landing-inset);
    margin-top: 0.25rem;
    border-radius: 0.85rem;
    overflow: visible;
    background: var(--speech-landing-bg);
    color: var(--ks-text);
    font-family: "Google Sans", Roboto, Arial, sans-serif;
}

.speech-home {
    display: flex;
    flex-direction: column;
    gap: var(--speech-landing-inset, 0.5rem);
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.speech-page-part {
    position: relative;
    overflow: hidden;
    border-radius: 0.85rem;
    width: 100%;
    box-sizing: border-box;
}

.speech-page-part--hero {
    flex-shrink: 0;
    overflow: visible;
    display: flex;
    flex-direction: column;
    gap: var(--speech-landing-inset, 0.5rem);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.speech-page-part--body {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.speech-module--landing .speech-page-shell .speech-page-part--body {
    margin-bottom: var(--speech-landing-inset);
}

.speech-page__media {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    border-radius: inherit;
}

.speech-page__media::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.speech-landing-content,
.speech-page-body {
    --speech-page-body-inset: 0.25rem;
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    gap: var(--speech-landing-inset, 0.5rem);
    padding: var(--speech-page-body-inset);
    box-sizing: border-box;
}

.speech-page-shell {
    display: flex;
    flex-direction: column;
    gap: var(--speech-landing-inset, 0.5rem);
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.speech-module--landing .speech-landing-content .speech-section:last-child {
    margin-bottom: 0;
}

.speech-landing-type-lead {
    margin-top: -0.35rem;
    margin-bottom: 1.25rem;
    color: var(--ks-accent-deep, var(--tts-accent-deep, #311b92));
    opacity: 0.88;
}

.speech-page-part--inspiration {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.speech-inspiration {
    position: relative;
    overflow: hidden;
    border-radius: inherit;
}

.speech-inspiration .speech-hero-media {
    position: absolute;
    inset: 0;
}

.speech-inspiration-overlay {
    position: relative;
    z-index: 1;
    padding-block: 1.25rem 1.5rem;
    padding-inline: max(var(--speech-gutter, 0.5rem), env(safe-area-inset-left, 0px)) max(var(--speech-gutter, 0.5rem), env(safe-area-inset-right, 0px));
    color: #fff;
}

.speech-inspiration-title {
    color: #fff;
    margin-bottom: 1rem;
}

.speech-carousel-slide--themed {
    min-height: 220px;
    border-radius: 0.75rem;
    background: rgba(0, 0, 0, 0.22);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

.speech-inspiration .speech-carousel-indicators [data-bs-target],
.speech-inspiration .carousel-indicators [data-bs-target] {
    background-color: rgba(255, 255, 255, 0.45);
}

.speech-inspiration .carousel-indicators .active {
    background-color: #fff;
}

.speech-hero {
    position: relative;
    border-radius: 0.85rem;
    overflow: hidden;
    margin-bottom: 0;
    min-height: 220px;
    display: flex;
    align-items: flex-end;
    --speech-hero-btn-secondary-bg: rgba(255, 255, 255, 0.14);
    --speech-hero-btn-secondary-border: rgba(255, 255, 255, 0.5);
    --speech-hero-btn-secondary-text: #fff;
    --speech-hero-btn-secondary-hover-bg: rgba(255, 255, 255, 0.22);
    --speech-hero-btn-secondary-hover-text: #fff;
    --speech-hero-btn-outline-bg: rgba(255, 255, 255, 0.1);
    --speech-hero-btn-outline-border: rgba(255, 255, 255, 0.55);
    --speech-hero-btn-outline-text: #fff;
    --speech-hero-btn-outline-hover-bg: rgba(255, 255, 255, 0.22);
    --speech-hero-btn-outline-hover-border: rgba(255, 255, 255, 0.9);
    --speech-hero-btn-outline-hover-text: #fff;
}

.speech-hero-media {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(135deg, rgba(69, 39, 160, 0.25) 0%, rgba(49, 27, 146, 0.72) 100%),
        linear-gradient(145deg, #311b92 0%, #4527a0 35%, #673ab7 60%, #512da8 100%);
}

.speech-hero-media::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 15% 85%, rgba(179, 157, 219, 0.28) 0%, transparent 45%),
        radial-gradient(circle at 85% 15%, rgba(126, 87, 194, 0.22) 0%, transparent 40%);
}

.speech-hero-overlay {
    position: relative;
    z-index: 1;
    width: 100%;
    padding: 1.25rem 1.5rem;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.82) 0%, rgba(0, 0, 0, 0.25) 70%, transparent 100%);
    color: #fff;
    overflow: visible;
}

.speech-hero-layout {
    position: relative;
    display: block;
}

.speech-hero-copy {
    min-width: 0;
    width: 100%;
}

.speech-hero-figure {
    position: absolute;
    top: 0;
    right: 0;
    z-index: 2;
    display: block;
    width: auto;
    max-width: min(280px, 36vw);
    max-height: min(180px, 38vh);
    height: auto;
    object-fit: contain;
    object-position: top right;
    pointer-events: none;
    user-select: none;
}

.speech-hero-title {
    font-size: clamp(1.35rem, 2.6vw, 1.9rem);
    font-weight: 700;
    line-height: 1.25;
    max-width: none;
    width: 100%;
    margin: 0 0 0.5rem;
}

.speech-hero-sub {
    max-width: none;
    width: 100%;
    opacity: 0.92;
    margin: 0 0 1rem;
    line-height: 1.45;
    font-size: 0.9375rem;
}

.speech-hero--compact {
    min-height: 7rem;
}

.speech-hero--compact .speech-hero-overlay {
    padding: 1rem 1.25rem;
}

.speech-hero--compact .speech-hero-title {
    font-size: clamp(1.2rem, 2.2vw, 1.55rem);
    margin-bottom: 0.35rem;
}

.speech-hero--compact .speech-hero-sub {
    margin-bottom: 0;
}

.speech-module .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: var(--space-sm, 8px) var(--space-md, 12px);
    border-radius: var(--radius-md, 8px);
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: 0.15s ease;
    width: 100%;
    max-width: 450px;
    margin: 0 auto;
    margin-top: var(--space-sm, 8px);
    margin-bottom: var(--space-sm, 8px);
    box-sizing: border-box;
    font-family: inherit;
}

.speech-module .ks-module-top-bar {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0.75rem;
    flex-wrap: nowrap;
    width: 100%;
    margin-bottom: 0;
    box-sizing: border-box;
    --ks-top-bar-gutter: var(--space-md, 12px);
    margin-left: calc(-1 * var(--ks-top-bar-gutter));
    margin-right: calc(-1 * var(--ks-top-bar-gutter));
    width: calc(100% + 2 * var(--ks-top-bar-gutter));
    padding-left: max(env(safe-area-inset-left, 0px), 0.65rem);
    padding-right: calc(var(--ks-top-bar-gutter) + env(safe-area-inset-right, 0px));
}

.speech-module--landing .ks-module-top-bar {
    --ks-top-bar-gutter: var(--speech-landing-inset, 0.5rem);
}

.speech-module .ks-module-top-bar__start {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0.5rem;
    flex: 0 0 auto;
    min-width: 0;
}

.speech-module .ks-module-top-bar__end {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex: 0 0 auto;
    margin-left: auto;
}

.speech-module .ks-module-top-bar__back,
.speech-module .ks-module-top-bar__primary {
    width: auto;
    max-width: none;
    margin: 0;
    white-space: nowrap;
}

.speech-module .ks-module-top-bar__back {
    min-height: 2rem;
    padding: 0.35rem 0.85rem;
    font-size: 0.9rem;
    font-weight: 600;
    line-height: 1.25;
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
    border-top-right-radius: var(--radius-md, 8px);
    border-bottom-right-radius: var(--radius-md, 8px);
}

.speech-module--landing .btn-secondary,
.speech-module--landing .ks-module-top-bar__back {
    background: var(--tts-btn-secondary-bg, #fff);
    border: 1px solid var(--tts-btn-secondary-border, var(--ks-border));
    color: var(--tts-btn-secondary-text, var(--ks-accent-deep));
}

.speech-module--landing .btn-secondary:hover,
.speech-module--landing .btn-secondary:focus,
.speech-module--landing .btn-secondary:focus-visible,
.speech-module--landing .ks-module-top-bar__back:hover,
.speech-module--landing .ks-module-top-bar__back:focus,
.speech-module--landing .ks-module-top-bar__back:focus-visible {
    background: var(--tts-btn-secondary-hover-bg, #f8f9fa);
    border-color: var(--tts-btn-secondary-border-hover, var(--tts-btn-secondary-border, var(--ks-border)));
    color: var(--tts-btn-secondary-text-hover, var(--tts-btn-secondary-text, var(--ks-accent-deep)));
}

.speech-module .ks-module-top-bar__end .ks-balance-bar--embedded {
    justify-content: flex-end;
}

@media (max-width: 576px) {
    .speech-module--landing .ks-module-top-bar {
        --ks-top-bar-gutter: var(--speech-landing-inset, 0.35rem);
    }
}

.speech-module--landing .speech-page-body .speech-panel,
.speech-module--landing .speech-page-body .speech-auth-notice {
    background: var(--speech-panel-bg);
    border: 1px solid var(--speech-panel-border);
    border-radius: 0.75rem;
    box-shadow: 0 1px 2px rgba(60, 64, 67, 0.08);
    padding: 1.25rem 1rem;
}

.speech-page-body .speech-panel > .speech-panel-title:first-child,
.speech-page-body .speech-panel > .speech-panel-lead:first-of-type,
.speech-page-body .speech-info-panel > .speech-info-page-title,
.speech-page-body .speech-info-panel > .speech-info-lead,
.speech-page-body .speech-list-header .speech-panel-title,
.speech-page-body .speech-demo-header .speech-panel-title,
.speech-page-body .speech-demo-header .speech-panel-lead,
.speech-page-body .speech-payment-cancelled > .speech-panel-title,
.speech-page-body .speech-payment-cancelled > .speech-payment-cancelled-lead,
.speech-page-body .speech-payment-success-panel > .speech-panel-title,
.speech-page-body .speech-payment-success-panel > .speech-payment-success-message,
.speech-page-body .speech-editor-header .speech-panel-title {
    display: none;
}

.speech-hero-actions-main {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.speech-module .speech-hero .speech-btn--outline.e-btn,
.speech-module .speech-hero .speech-btn--tips.e-btn,
.speech-module .speech-hero .speech-btn--info.e-btn,
.speech-module .speech-hero .speech-btn--host.e-btn {
    background: var(--speech-hero-btn-outline-bg) !important;
    border: 1px solid var(--speech-hero-btn-outline-border) !important;
    color: var(--speech-hero-btn-outline-text) !important;
    box-shadow: none !important;
}

.speech-module .speech-hero .speech-btn--outline.e-btn:hover,
.speech-module .speech-hero .speech-btn--outline.e-btn:focus,
.speech-module .speech-hero .speech-btn--outline.e-btn:focus-visible,
.speech-module .speech-hero .speech-btn--tips.e-btn:hover,
.speech-module .speech-hero .speech-btn--tips.e-btn:focus,
.speech-module .speech-hero .speech-btn--tips.e-btn:focus-visible,
.speech-module .speech-hero .speech-btn--info.e-btn:hover,
.speech-module .speech-hero .speech-btn--info.e-btn:focus,
.speech-module .speech-hero .speech-btn--info.e-btn:focus-visible,
.speech-module .speech-hero .speech-btn--host.e-btn:hover,
.speech-module .speech-hero .speech-btn--host.e-btn:focus,
.speech-module .speech-hero .speech-btn--host.e-btn:focus-visible {
    background: var(--speech-hero-btn-outline-hover-bg) !important;
    border-color: var(--speech-hero-btn-outline-hover-border) !important;
    color: var(--speech-hero-btn-outline-hover-text) !important;
}

/* Host-knapp: diskret amber-kant på mørke heroer, lesbar på lyse */
.speech-module .speech-hero .speech-btn--host.e-btn {
    border-color: var(--speech-hero-btn-host-border, rgba(251, 191, 36, 0.72)) !important;
}

.speech-module .speech-hero .speech-btn--host.e-btn:hover,
.speech-module .speech-hero .speech-btn--host.e-btn:focus,
.speech-module .speech-hero .speech-btn--host.e-btn:focus-visible {
    border-color: var(--speech-hero-btn-host-hover-border, rgba(251, 191, 36, 0.95)) !important;
}

.speech-btn.e-btn,
.speech-btn {
    border-radius: 0.5rem !important;
    font-weight: 600 !important;
    padding: 0.65rem 1.25rem !important;
}

.speech-module .speech-hero .speech-btn--primary.e-btn {
    background: linear-gradient(135deg, var(--tts-btn-primary-start, #9575cd) 0%, var(--tts-btn-primary-end, #673ab7) 100%) !important;
    border: none !important;
    color: var(--tts-btn-primary-text, #fff) !important;
    box-shadow: 0 4px 14px var(--tts-btn-primary-shadow, rgba(103, 58, 183, 0.24)) !important;
}

.speech-module .speech-hero .speech-btn--secondary.e-btn {
    background: var(--speech-hero-btn-secondary-bg) !important;
    border: 1px solid var(--speech-hero-btn-secondary-border) !important;
    color: var(--speech-hero-btn-secondary-text) !important;
}

.speech-module .speech-hero .speech-btn--secondary.e-btn:hover,
.speech-module .speech-hero .speech-btn--secondary.e-btn:focus,
.speech-module .speech-hero .speech-btn--secondary.e-btn:focus-visible {
    background: var(--speech-hero-btn-secondary-hover-bg) !important;
    border-color: var(--speech-hero-btn-secondary-border) !important;
    color: var(--speech-hero-btn-secondary-hover-text) !important;
}

.speech-module .speech-hero .speech-btn--primary.e-btn:hover,
.speech-module .speech-hero .speech-btn--primary.e-btn:focus,
.speech-module .speech-hero .speech-btn--primary.e-btn:focus-visible {
    color: var(--tts-btn-primary-text, #fff) !important;
    filter: brightness(1.06);
}

.speech-btn--primary.e-btn {
    background: linear-gradient(135deg, var(--tts-btn-primary-start, #f59e0b) 0%, var(--tts-btn-primary-end, #d97706) 100%) !important;
    border: none !important;
    color: var(--tts-btn-primary-text, #fff) !important;
}

.speech-btn--secondary.e-btn {
    background: transparent !important;
    border: 2px solid rgba(255, 255, 255, 0.85) !important;
    color: #fff !important;
}

.speech-section {
    margin-bottom: 2.5rem;
}

.speech-module--landing .speech-landing-content .speech-section {
    margin-bottom: 0;
    background: var(--speech-panel-bg);
    border: 1px solid var(--speech-panel-border);
    border-radius: 0.75rem;
    padding: 1.25rem 1rem;
}

.speech-section-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1.25rem;
    color: var(--ks-accent-deep, var(--tts-accent-deep, #311b92));
}

.speech-seo-section {
    background: linear-gradient(180deg, #faf5ff 0%, #fff 100%);
    border: 1px solid #e9d5ff;
    border-radius: 0.75rem;
    padding: 1.5rem 1.25rem;
}

.speech-module--landing .speech-landing-content .speech-seo-section {
    background: var(--speech-panel-bg);
    border: 1px solid var(--speech-panel-border);
    border-radius: 0.75rem;
    padding: 1.25rem 1rem;
    box-shadow: none;
}

.speech-seo-lead {
    font-size: 1.05rem;
    line-height: 1.6;
    color: #374151;
    margin: 0 0 1.25rem;
}

.speech-seo-block {
    margin-bottom: 1.25rem;
}

.speech-seo-block:last-child {
    margin-bottom: 0;
}

.speech-seo-block h3 {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--ks-accent-deep, var(--tts-accent-deep, #311b92));
    margin: 0 0 0.5rem;
}

.speech-seo-block p {
    margin: 0 0 0.65rem;
    line-height: 1.55;
    color: #4b5563;
}

.speech-seo-block p:last-child {
    margin-bottom: 0;
}

/* Felles korttekst – samme farge som prislinjen */
.speech-type-card,
.speech-tier-card {
    color: #4c1d95;
}

.speech-type-card {
    height: 100%;
    padding: 1.25rem;
    border-radius: 0.75rem;
    border: 1px solid #e5e7eb;
    background: #fff;
    box-shadow: 0 0.25rem 1rem rgba(30, 27, 75, 0.06);
}

.speech-type-card h3,
.speech-tier-card h3 {
    font-size: 1.05rem;
    font-weight: 700;
    margin: 0.75rem 0 0.35rem;
    color: var(--ks-accent-deep, var(--tts-accent-deep, #311b92));
}

.speech-type-card p,
.speech-tier-card ul,
.speech-tier-card li {
    color: #4c1d95;
    opacity: 1;
}

.speech-type-card p {
    margin-bottom: 0;
}

.speech-tier-card ul {
    margin: 0.75rem 0 0;
    padding-left: 1.15rem;
}

.speech-type-icon {
    color: #4c1d95;
}

.speech-tier-card {
    height: 100%;
    padding: 1.25rem;
    border-radius: 0.75rem;
    border: 1px solid #e5e7eb;
    background: #fff;
}

.speech-tier-card--basic { border-top: 4px solid #94a3b8; }
.speech-tier-card--pro { border-top: 4px solid #7c3aed; }
.speech-tier-card--premium { border-top: 4px solid #f59e0b; }

.speech-tier-price {
    font-size: 1.35rem;
    font-weight: 700;
    color: #4c1d95;
    margin: 0.35rem 0 0;
}

.speech-carousel-slide {
    min-height: 280px;
    border-radius: 0.75rem;
    background: linear-gradient(135deg, hsl(var(--speech-slide-hue, 260), 55%, 42%) 0%, #1e1b4b 100%);
    display: flex;
    align-items: flex-end;
}

.speech-carousel-caption {
    color: #fff;
    padding: 2rem;
    background: linear-gradient(to top, rgba(0,0,0,0.75), transparent);
    width: 100%;
}

.speech-panel {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 0.85rem;
    padding: 1.5rem;
    box-shadow: 0 0.35rem 1.25rem rgba(30, 27, 75, 0.06);
}

/* Felles paneltema – samme farger som betaling / mine tekster / priskort */
.speech-module .speech-panel {
    color: #4c1d95;
}

.speech-module .speech-panel .speech-panel-title,
.speech-module .speech-panel h3 {
    color: var(--ks-accent-deep, var(--tts-accent-deep, #311b92));
}

.speech-module .speech-panel .speech-panel-lead {
    color: #4c1d95;
    opacity: 0.88;
    margin-bottom: 1.25rem;
}

.speech-module .speech-panel p,
.speech-module .speech-panel label,
.speech-module .speech-form-hint {
    margin: 0 0 0.35rem;
    font-size: 0.9rem;
    color: var(--speech-muted, #5c6370);
}

.speech-module .speech-form-hint--warn {
    color: #9a3412;
}

.speech-module .speech-file-upload {
    margin-bottom: 0.75rem;
}

.speech-module .speech-file-upload-label {
    display: block;
    margin-bottom: 0.35rem;
    font-weight: 600;
}

.speech-module .speech-file-input {
    display: block;
    max-width: 100%;
    font-size: 0.9rem;
}

.speech-module .speech-form label {
    color: #4c1d95;
    opacity: 1;
}

.speech-module .speech-panel .speech-ai-message {
    color: #4c1d95;
    opacity: 0.82;
}

.speech-module .speech-panel .speech-select-card,
.speech-module .speech-panel .speech-select-card strong,
.speech-module .speech-panel .speech-tier-select,
.speech-module .speech-panel .speech-tier-select h3,
.speech-module .speech-panel .speech-tier-select li,
.speech-module .speech-panel .speech-tier-select small {
    color: #4c1d95;
}

.speech-module .speech-panel .speech-tier-select-price {
    color: #4c1d95;
}

.speech-module .speech-panel .speech-export-preview pre {
    color: #4c1d95;
}

.speech-module .speech-panel .e-btn.e-primary,
.speech-module .speech-panel .speech-btn--pay.e-btn {
    background: linear-gradient(135deg, #7c3aed 0%, #4c1d95 100%) !important;
    border: none !important;
    color: #fff !important;
    border-radius: 0.5rem !important;
    font-weight: 600 !important;
    padding: 0.65rem 1.25rem !important;
}

.speech-module .speech-panel .e-btn.e-primary:hover:not(:disabled),
.speech-module .speech-panel .speech-btn--pay.e-btn:hover:not(:disabled) {
    background: linear-gradient(135deg, #6d28d9 0%, #4338ca 100%) !important;
    color: #fff !important;
}

.speech-module .speech-panel .e-btn.e-primary:disabled,
.speech-module .speech-panel .speech-btn--pay.e-btn:disabled {
    opacity: 0.65;
}

.speech-module .speech-panel .speech-btn--outline.e-btn,
.speech-module .speech-panel .e-btn.e-outline,
.speech-module .speech-panel .speech-panel-actions .e-btn:not(.e-primary):not(.speech-btn--pay) {
    background: transparent !important;
    border: 2px solid #4c1d95 !important;
    color: #4c1d95 !important;
    border-radius: 0.5rem !important;
    font-weight: 600 !important;
}

.speech-module .speech-panel .speech-btn--outline.e-btn:hover,
.speech-module .speech-panel .e-btn.e-outline:hover,
.speech-module .speech-panel .speech-panel-actions .e-btn:not(.e-primary):not(.speech-btn--pay):hover {
    background: rgba(76, 29, 149, 0.08) !important;
    color: #4c1d95 !important;
}

.speech-panel-title {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 0.35rem;
}

.speech-panel-lead {
    margin-bottom: 1.25rem;
}

.speech-panel-actions {
    display: flex;
    gap: 0.75rem;
    margin-top: 1.5rem;
}

.speech-form label {
    display: block;
    font-weight: 600;
    margin: 0.75rem 0 0.35rem;
}

.speech-select-card,
.speech-tier-select {
    width: 100%;
    text-align: left;
    padding: 1rem;
    border-radius: 0.75rem;
    border: 2px solid #e5e7eb;
    background: #fff;
    transition: border-color 0.15s, box-shadow 0.15s;
}

.speech-select-card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.35rem;
    min-height: 100%;
    cursor: pointer;
}

.speech-select-card-icon {
    color: hsl(var(--speech-hue, 270), 55%, 42%);
    line-height: 0;
    margin-bottom: 0.15rem;
}

.speech-select-card strong {
    display: block;
    font-size: 0.98rem;
    line-height: 1.3;
    color: var(--ks-accent-deep, var(--tts-accent-deep, #311b92));
}

.speech-select-card-desc {
    margin: 0;
    font-size: 0.82rem;
    font-weight: 400;
    line-height: 1.4;
    color: #5b21b6;
    opacity: 0.92;
}

.speech-select-card.is-selected,
.speech-tier-select.is-selected {
    border-color: #7c3aed;
    box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.15);
}

.speech-tier-select-price {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--ks-accent-deep, var(--tts-accent-deep, #311b92));
}

.speech-payment-summary {
    padding: 1rem;
    border-radius: 0.65rem;
    background: #fff;
    border: 1px solid #e5e7eb;
    margin-bottom: 1rem;
    color: #4c1d95;
}

.speech-payment-summary p {
    color: #4c1d95;
    opacity: 1;
    margin-bottom: 0.35rem;
}

.speech-payment-summary p:last-child {
    margin-bottom: 0;
}

.speech-payment-title strong {
    font-size: 1.05rem;
    font-weight: 700;
    color: #4c1d95;
}

.speech-payment-meta {
    font-weight: 600;
    color: #4c1d95;
}

.speech-payment-amount {
    font-size: 1.35rem;
    font-weight: 700;
    color: #4c1d95;
    margin-top: 0.5rem;
}

.speech-payment-email-intro,
.speech-payment-email-sent p {
    color: #4c1d95;
    margin-bottom: 1rem;
    line-height: 1.5;
}

.speech-payment-email-hint {
    font-size: 0.9rem;
    opacity: 0.85;
}

.speech-payment-cancelled {
    color: #4c1d95;
}

.speech-payment-cancelled-lead {
    margin-bottom: 1.25rem;
    line-height: 1.55;
}

.speech-panel-actions--stack {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    align-items: flex-start;
}

.speech-paid-badge {
    display: inline-block;
    padding: 0.35rem 0.75rem;
    border-radius: 999px;
    background: #dcfce7;
    color: #166534;
    font-weight: 600;
    margin-bottom: 1rem;
}

.speech-payment-success-panel {
    text-align: center;
    max-width: 520px;
    margin: 0 auto;
}

.speech-payment-success-panel .speech-panel-title {
    margin-bottom: 0.75rem;
}

.speech-payment-success-message {
    font-size: 1.05rem;
    line-height: 1.6;
    margin-bottom: 1.25rem;
    font-weight: 600;
}

.speech-payment-success-panel .speech-payment-summary {
    text-align: left;
    margin-bottom: 1.5rem;
}

.speech-payment-success-panel .speech-panel-actions {
    justify-content: center;
    margin-top: 0.5rem;
}

.speech-revision-exhausted {
    padding: 1rem 1.25rem;
    margin-bottom: 1.25rem;
    border-radius: 0.65rem;
    border: 1px solid #c4b5fd;
    background: #f5f3ff;
    color: #4c1d95;
}

.speech-revision-exhausted p {
    margin-bottom: 0.75rem;
    font-weight: 600;
    line-height: 1.5;
}

.speech-list-panel .speech-empty {
    color: #4c1d95;
    opacity: 1;
    font-weight: 600;
    padding: 1.5rem 0;
}

.speech-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.speech-list-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    padding: 1.25rem;
    border: 1px solid #e5e7eb;
    border-radius: 0.75rem;
    background: #fff;
    box-shadow: 0 0.25rem 1rem rgba(30, 27, 75, 0.06);
}

.speech-list-item-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--ks-accent-deep, var(--tts-accent-deep, #311b92));
    margin: 0 0 0.35rem;
}

.speech-list-item-meta,
.speech-list-item-revisions,
.speech-list-item-date {
    color: #4c1d95;
    opacity: 1;
    margin: 0 0 0.25rem;
    font-weight: 600;
}

.speech-list-item-revisions--none {
    color: #b45309;
}

.speech-list-item-date {
    font-weight: 500;
    font-size: 0.95rem;
}

.speech-status {
    display: inline-block;
    font-size: 0.8rem;
    font-weight: 700;
    padding: 0.25rem 0.65rem;
    border-radius: 999px;
    margin-top: 0.5rem;
}

.speech-status--paid {
    background: #ede9fe;
    color: #4c1d95;
    border: 1px solid #c4b5fd;
}

.speech-status--draft {
    background: #fef3c7;
    color: #78350f;
    border: 1px solid #fcd34d;
}

.speech-list-item-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    flex-shrink: 0;
    align-items: center;
}

.speech-module .speech-panel .speech-btn--danger.e-btn {
    color: #991b1b;
    border-color: #fca5a5;
    background: #fff;
}

.speech-module .speech-panel .speech-btn--danger.e-btn:hover:not(:disabled) {
    color: #fff;
    background: #dc2626;
    border-color: #dc2626;
}

.speech-list-panel .speech-list-header .speech-btn--pay.e-btn,
.speech-list-panel .speech-list-item-actions .speech-btn--pay.e-btn {
    flex-shrink: 0;
}

.speech-editor-panel {
    position: relative;
}

.speech-ai-loading-overlay {
    position: absolute;
    inset: 0;
    z-index: 30;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 2rem 1.5rem;
    text-align: center;
    background: rgba(255, 255, 255, 0.88);
    border-radius: inherit;
    border: 1px solid #c4b5fd;
}

.speech-ai-loading-overlay .speech-ai-loading-title {
    margin: 0;
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--ks-accent-deep, var(--tts-accent-deep, #311b92));
}

.speech-ai-loading-overlay .speech-ai-loading-detail {
    margin: 0;
    font-size: 0.95rem;
    font-weight: 500;
    color: #5b21b6;
    max-width: 26rem;
    line-height: 1.5;
}

.speech-editor-panel .speech-editor-header {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

.speech-editor-panel .speech-editor-header p {
    font-weight: 600;
    margin: 0.25rem 0 0;
}

.speech-editor-panel .speech-editor-actions-top {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.speech-contact-panel .speech-contact-meta {
    margin-bottom: 1.25rem;
    padding: 1rem 1.25rem;
    border-radius: 0.65rem;
    border: 1px solid #c4b5fd;
    background: #f5f3ff;
    color: #4c1d95;
}

.speech-contact-panel .speech-contact-meta p {
    margin: 0 0 0.35rem;
    font-weight: 600;
}

.speech-contact-panel .speech-contact-meta p:last-child {
    margin-bottom: 0;
}

.speech-contact-panel .speech-contact-label {
    display: block;
    font-weight: 700;
    color: #4c1d95;
    margin-bottom: 0.5rem;
}

.speech-contact-panel .speech-contact-form {
    margin-bottom: 1.25rem;
}

.speech-editor-panel .speech-chat {
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    border-radius: 0.65rem;
    padding: 1rem;
    height: 100%;
}

.speech-editor-setup {
    margin-top: 2.5rem;
    padding: 1rem 1.1rem;
    border-radius: 0.75rem;
    border: 1px solid #bfdbfe;
    background: #eff6ff;
}

.speech-editor-setup-summary {
    cursor: pointer;
    font-size: 1.05rem;
    font-weight: 700;
    color: #1e40af;
}

.speech-editor-setup-lead {
    margin: 0.5rem 0 0.85rem;
    color: #1d4ed8;
    font-size: 0.92rem;
    font-weight: 500;
}

.speech-editor-setup-grid {
    display: grid;
    gap: 0.85rem;
}

.speech-editor-setup-label {
    display: block;
    font-weight: 700;
    color: #1e40af;
    margin-bottom: 0.35rem;
}

.speech-editor-setup-value {
    margin: 0;
    padding: 0.75rem 0.85rem;
    border-radius: 0.65rem;
    border: 1px solid #e5e7eb;
    background: #fff;
    white-space: pre-wrap;
    word-break: break-word;
    color: #1f2937;
    font-family: inherit;
    font-size: 0.95rem;
}

.speech-editor-revision-label {
    display: block;
    font-weight: 700;
    color: #4c1d95;
    margin-bottom: 0.35rem;
}

.speech-editor-revision-select {
    max-width: 20rem;
    margin-bottom: 0.85rem;
}

.speech-editor-text-title {
    margin: 0 0 0.65rem;
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--ks-accent-deep, var(--tts-accent-deep, #311b92));
}

.speech-editor-readonly-content,
.speech-editor-readonly-prompt {
    margin: 0;
    padding: 1rem;
    min-height: 12rem;
    border-radius: 0.65rem;
    border: 1px solid #e5e7eb;
    background: #f8fafc;
    white-space: pre-wrap;
    word-break: break-word;
    color: #1f2937;
    font-family: inherit;
    font-size: 0.95rem;
}

.speech-editor-readonly-prompt {
    min-height: 6rem;
}

.speech-revision-view-hint {
    margin: 0.65rem 0 0;
    font-size: 0.88rem;
    color: #5b21b6;
    line-height: 1.45;
}

.speech-revision-next-prompt-label {
    margin: 0.85rem 0 0.45rem;
    font-size: 0.92rem;
    font-weight: 700;
    color: #4c1d95;
}

.speech-editor-panel .speech-chat .e-btn {
    margin-top: 0.75rem;
}

.speech-editor-panel .col-lg-7 > .e-btn {
    margin-top: 0.75rem;
}

.speech-editor-text-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 0.75rem;
}

.speech-editor-text-actions .e-btn {
    margin-top: 0;
}

.speech-ai-message {
    margin-top: 0.75rem;
    font-size: 0.92rem;
}

.speech-revision-prompt-hint {
    margin: 0.5rem 0 0;
    font-size: 0.88rem;
    color: #b45309;
    line-height: 1.4;
}

.speech-export-panel .speech-export-preview {
    margin-top: 0.5rem;
}

.speech-export-panel .speech-export-preview pre {
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    border-radius: 0.65rem;
    padding: 1rem;
    max-height: 420px;
    overflow: auto;
    white-space: pre-wrap;
    word-break: break-word;
}

.speech-export-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.speech-auth-notice {
    text-align: center;
    padding: 2rem;
    color: #4c1d95;
}

.speech-auth-notice p {
    color: #4c1d95;
    font-weight: 600;
}

.speech-list-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.25rem;
    flex-wrap: wrap;
}

.speech-list-header-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
}

.speech-info-panel {
    max-width: 52rem;
}

.speech-info-page-title {
    font-size: clamp(1.5rem, 2.5vw, 2rem);
    font-weight: 700;
    color: var(--ks-accent-deep, var(--tts-accent-deep, #311b92));
    margin: 0 0 0.75rem;
    line-height: 1.25;
}

.speech-info-lead {
    margin-bottom: 1.5rem;
}

.speech-info-section {
    margin-bottom: 2rem;
}

.speech-info-heading {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--ks-accent-deep, var(--tts-accent-deep, #311b92));
    margin: 0 0 0.75rem;
}

.speech-info-section p {
    margin: 0 0 0.75rem;
    color: #374151;
    line-height: 1.6;
}

.speech-info-types-list {
    margin: 0;
    padding-left: 1.35rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    color: #374151;
    line-height: 1.55;
}

.speech-info-types-list strong {
    color: var(--ks-accent-deep, var(--tts-accent-deep, #311b92));
}

.speech-info-steps {
    margin: 0 0 1rem;
    padding-left: 1.35rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    color: #374151;
    line-height: 1.55;
}

.speech-info-tip {
    margin: 0;
    padding: 0.75rem 1rem;
    border-left: 3px solid #a78bfa;
    background: #faf5ff;
    border-radius: 0 0.35rem 0.35rem 0;
    color: #4b5563;
    font-size: 0.95rem;
}

.speech-info-why-list {
    margin: 0 0 1rem;
    padding-left: 1.35rem;
    color: #374151;
    line-height: 1.55;
}

.speech-info-table-wrap {
    overflow-x: auto;
    margin: 1rem 0;
}

.speech-info-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.95rem;
}

.speech-info-table th,
.speech-info-table td {
    border: 1px solid #ddd6fe;
    padding: 0.65rem 0.85rem;
    text-align: left;
    vertical-align: top;
}

.speech-info-table thead th {
    background: #ede9fe;
    color: var(--ks-accent-deep, var(--tts-accent-deep, #311b92));
    font-weight: 700;
}

.speech-info-table tbody th[scope="row"] {
    background: #faf5ff;
    color: var(--ks-accent-deep, var(--tts-accent-deep, #311b92));
    font-weight: 600;
    white-space: nowrap;
}

.speech-tips-panel {
    max-width: 48rem;
}

.speech-tips-heading {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--ks-accent-deep, var(--tts-accent-deep, #311b92));
    margin: 1.5rem 0 0.75rem;
}

.speech-tips-heading:first-of-type {
    margin-top: 0.5rem;
}

.speech-tips-list {
    margin: 0;
    padding-left: 1.35rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.speech-tips-item strong {
    display: block;
    color: var(--ks-accent-deep, var(--tts-accent-deep, #311b92));
    margin-bottom: 0.25rem;
}

.speech-tips-item p {
    margin: 0;
    color: #374151;
    line-height: 1.55;
}

.speech-tips-examples-intro {
    margin: 0 0 1.25rem;
    color: #4b5563;
}

.speech-tips-type-block {
    margin-bottom: 2rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #e9d5ff;
}

.speech-tips-type-block:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.speech-tips-type-heading {
    font-size: 1rem;
    font-weight: 700;
    color: var(--ks-accent-deep, var(--tts-accent-deep, #311b92));
    margin: 0 0 0.35rem;
}

.speech-tips-type-lead {
    margin: 0 0 1rem;
    font-size: 0.9rem;
    color: #6b7280;
    line-height: 1.45;
}

.speech-tips-example {
    margin-bottom: 1rem;
    padding: 0.85rem 1rem;
    border: 1px solid #c4b5fd;
    border-radius: 0.5rem;
    background: #faf5ff;
}

.speech-tips-example-label {
    font-size: 0.95rem;
    font-weight: 700;
    color: #4c1d95;
    margin: 0 0 0.5rem;
}

.speech-tips-example-body {
    margin: 0;
    padding: 0;
    font-family: inherit;
    font-size: 0.9rem;
    line-height: 1.5;
    white-space: pre-wrap;
    word-break: break-word;
    color: #1f2937;
    background: transparent;
    border: none;
}

.speech-tips-note {
    padding: 0.85rem 1rem;
    border-radius: 0.5rem;
    background: #ede9fe;
    border: 1px solid #c4b5fd;
}

.speech-tips-note p {
    margin: 0;
    line-height: 1.55;
    color: #374151;
}

.speech-footer {
    margin-top: 2.5rem;
    padding: 2rem 1.5rem;
    border-radius: 0.85rem;
    border: 2px solid #4c1d95;
    outline: 1px solid #c4b5fd;
    outline-offset: 4px;
    box-shadow:
        0 0 0 1px rgba(255, 255, 255, 0.6) inset,
        0 0.5rem 1.5rem rgba(76, 29, 149, 0.15);
    background: linear-gradient(145deg, #f5f3ff 0%, #ede9fe 100%);
    color: #4c1d95;
}

.speech-module--landing .speech-footer {
    margin: 0;
    padding: 1.25rem 1rem;
    border: 1px solid var(--speech-panel-border);
    outline: none;
    box-shadow: 0 1px 2px rgba(60, 64, 67, 0.08);
    background: var(--speech-panel-bg);
}

.speech-footer-inner {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1.5rem 2rem;
}

.speech-footer-title {
    font-size: 1.15rem;
    font-weight: 700;
    margin: 0 0 0.5rem;
}

.speech-footer-about {
    flex: 1 1 280px;
    max-width: 42rem;
}

.speech-footer-about p {
    margin: 0;
    line-height: 1.6;
    font-weight: 500;
}

.speech-footer-side {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
}

.speech-footer-company {
    padding: 0.85rem 1rem;
    border-radius: 0.5rem;
    border: 1px solid #a78bfa;
    background: rgba(255, 255, 255, 0.55);
}

.speech-footer-company-line {
    margin: 0 0 0.35rem;
    font-size: 0.95rem;
    line-height: 1.45;
}

.speech-footer-company-line:last-child {
    margin-bottom: 0;
}

.speech-footer-label {
    font-weight: 700;
    margin-right: 0.35rem;
}

.speech-footer-value {
    font-weight: 600;
}

.speech-public-contact-panel .speech-contact-form .speech-contact-label {
    margin-top: 1rem;
}

.speech-public-contact-panel .speech-contact-form .speech-contact-label:first-of-type {
    margin-top: 0;
}

.speech-host-maintenance-panel .speech-host-filter {
    margin-bottom: 1.25rem;
}

.speech-host-filter-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
}

.speech-host-section-title {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--ks-accent-deep, var(--tts-accent-deep, #311b92));
    margin: 1.5rem 0 0.75rem;
}

.speech-host-table-wrap {
    overflow-x: auto;
    border: 1px solid #c4b5fd;
    border-radius: 0.5rem;
    background: #fff;
}

.speech-host-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.88rem;
}

.speech-host-table th,
.speech-host-table td {
    padding: 0.5rem 0.65rem;
    border-bottom: 1px solid #e5e7eb;
    text-align: left;
    vertical-align: top;
}

.speech-host-table th {
    background: #ede9fe;
    color: var(--ks-accent-deep, var(--tts-accent-deep, #311b92));
    font-weight: 700;
    white-space: nowrap;
}

.speech-host-table tbody tr {
    cursor: pointer;
}

.speech-host-table tbody tr:hover {
    background: #f5f3ff;
}

.speech-host-row--selected {
    background: #ede9fe !important;
}

.speech-host-cell-title {
    max-width: 12rem;
}

.speech-host-maxrev-cell {
    min-width: 5.5rem;
    vertical-align: middle;
}

.speech-host-maxrev-cell .speech-host-maxrev-input.e-control-wrapper,
.speech-host-maxrev-cell .speech-host-maxrev-input.e-input-group {
    width: 5.5rem !important;
    min-width: 5.5rem;
}

.speech-host-maxrev-cell .speech-host-maxrev-input input.e-input {
    text-align: center;
    padding-left: 0.35rem;
    padding-right: 0.35rem;
}

.speech-host-edit-cell {
    vertical-align: middle;
    min-width: 7rem;
}

.speech-host-edit-cell .speech-host-dropdown.e-control-wrapper,
.speech-host-edit-cell .speech-host-dropdown.e-input-group {
    width: 100% !important;
    min-width: 0;
}

.speech-host-edit-cell .speech-host-dropdown input.e-input {
    font-size: 0.82rem;
    padding-left: 0.35rem;
    padding-right: 0.35rem;
}

.speech-host-details {
    margin: 1rem 0;
    padding: 0.75rem 1rem;
    border: 1px solid #c4b5fd;
    border-radius: 0.5rem;
    background: #faf5ff;
}

.speech-host-dl {
    display: grid;
    grid-template-columns: minmax(8rem, auto) 1fr;
    gap: 0.35rem 1rem;
    margin: 0.75rem 0 0;
}

.speech-host-dl dt {
    font-weight: 700;
    color: #4c1d95;
}

.speech-host-dl dd {
    margin: 0;
}

.speech-host-pre {
    white-space: pre-wrap;
    word-break: break-word;
}

.speech-host-forbidden {
    color: #991b1b;
    font-weight: 600;
}

.speech-btn--sm.e-btn {
    padding: 0.25rem 0.65rem;
    font-size: 0.82rem;
}

@media (max-width: 768px) {
    .speech-hero:not(.speech-hero--compact) { min-height: 340px; }
    .speech-hero--compact {
        min-height: 0;
        align-items: stretch;
    }
    .speech-hero--compact .speech-hero-overlay {
        padding: 0.75rem 1rem;
    }
    .speech-hero-layout {
        display: flex;
        flex-direction: column;
        gap: 0;
    }
    .speech-hero-copy {
        order: 1;
    }
    .speech-hero-aside {
        order: 2;
        width: 100%;
        max-width: none;
        margin-top: 1.5rem;
        padding-top: 0.5rem;
        align-items: center;
        justify-content: flex-start;
        gap: 1rem;
    }
    .speech-hero-figure {
        max-height: 200px;
        max-width: min(280px, 85vw);
        margin-inline: auto;
        object-position: center bottom;
    }
    .speech-module .speech-hero .speech-btn--host.e-btn {
        align-self: stretch;
        max-width: 280px;
        margin-inline: auto;
    }
    .speech-list-item { flex-direction: column; align-items: flex-start; }
    .speech-list-item-actions { width: 100%; }
    .speech-list-item-actions .e-btn { flex: 1 1 auto; }
    .speech-footer-side { width: 100%; }
}

/* Offline speech demo */
.speech-demo-panel {
    max-width: 100%;
    overflow-x: clip;
}

.speech-demo-panel .speech-demo-header-actions {
    justify-content: space-between;
    margin-top: 0;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 0.75rem;
}

.speech-demo-panel .speech-demo-header {
    flex: 1 1 14rem;
    min-width: 0;
    max-width: 100%;
}

.speech-demo-panel .speech-demo-inputs label {
    margin-top: 1rem;
}

.speech-demo-section-block {
    padding: 1rem 1.1rem;
    border-radius: 0.75rem;
    border: 1px solid #bfdbfe;
    background: #eff6ff;
    margin-bottom: 1.25rem;
    min-width: 0;
    max-width: 100%;
}

.speech-demo-section-block > label:first-of-type {
    margin-top: 0;
}

.speech-demo-revision-step-title {
    margin: 0 0 0.25rem;
    font-weight: 800;
    color: #1e40af;
}

.speech-demo-section-block .speech-demo-revision:last-child {
    margin-bottom: 0;
}

.speech-demo-chat-title {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--ks-accent-deep, var(--tts-accent-deep, #311b92));
    margin: 0 0 0.75rem;
}

.speech-demo-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin: 1rem 0 1.25rem;
}

.speech-demo-revisions-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--ks-accent-deep, var(--tts-accent-deep, #311b92));
    margin: 0 0 0.75rem;
}

.speech-demo-empty {
    color: #4c1d95;
    opacity: 0.85;
    font-weight: 600;
}

.speech-demo-revision {
    padding: 1rem 1.1rem;
    border-radius: 0.75rem;
    border: 1px solid #e5e7eb;
    background: #fff;
    box-shadow: 0 0.25rem 1rem rgba(30, 27, 75, 0.06);
    margin-bottom: 1rem;
    min-width: 0;
    max-width: 100%;
}

.speech-demo-revision-header {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 0.5rem;
    align-items: baseline;
    margin-bottom: 0.5rem;
}

.speech-demo-revision-meta {
    color: #4c1d95;
    opacity: 0.85;
    font-weight: 600;
    font-size: 0.9rem;
}

.speech-demo-revision-userprompt {
    color: #5b21b6;
    opacity: 0.95;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.speech-demo-revision-userprompt-label {
    margin-right: 0.35rem;
}

.speech-demo-revision-content {
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    border-radius: 0.65rem;
    padding: 1rem;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
    word-wrap: break-word;
    word-break: break-word;
    hyphens: auto;
    text-wrap: wrap;
    max-width: 100%;
    overflow-x: auto;
    color: #1f2937;
    font-family: inherit;
    margin: 0;
}

.speech-demo-panel .speech-panel-title,
.speech-demo-panel .speech-panel-lead,
.speech-demo-panel label,
.speech-demo-panel .speech-demo-chat-title,
.speech-demo-panel .speech-demo-revisions-title,
.speech-demo-panel .speech-demo-revision-step-title,
.speech-demo-panel .speech-demo-revision-header,
.speech-demo-panel .speech-demo-revision-header strong {
    overflow-wrap: anywhere;
    word-wrap: break-word;
    word-break: break-word;
    hyphens: auto;
    text-wrap: wrap;
    max-width: 100%;
}

.speech-demo-chat-box .speech-demo-revision-header {
    margin-bottom: 0.75rem;
}

.speech-demo-chat-input {
    min-height: 5rem;
}

.speech-demo-chat-input--empty {
    color: #6b7280;
}

@media (max-width: 768px) {
    .speech-demo-panel {
        padding: 1rem;
    }

    .speech-demo-panel .speech-demo-header-actions {
        flex-direction: column;
    }

    .speech-demo-panel .speech-demo-header-actions .e-btn {
        width: 100%;
    }

    .speech-demo-section-block,
    .speech-demo-revision {
        padding: 0.85rem;
    }

    .speech-demo-revision-content {
        padding: 0.75rem;
        font-size: 0.95rem;
        line-height: 1.55;
    }

    .speech-demo-panel .speech-panel-title {
        font-size: 1.2rem;
    }
}

.speech-demo-index-panel {
    max-width: 100%;
}

.speech-demo-index-panel .speech-demo-header {
    margin-bottom: 1.25rem;
}

.speech-demo-card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    width: 100%;
    height: 100%;
    min-height: 100%;
    padding: 1.15rem 1.2rem;
    border: 1px solid hsl(var(--speech-hue, 280), 45%, 82%);
    border-radius: 0.85rem;
    background: linear-gradient(145deg, hsl(var(--speech-hue, 280), 95%, 97%) 0%, #fff 100%);
    box-shadow: 0 0.35rem 1.1rem rgba(30, 27, 75, 0.07);
    text-align: left;
    cursor: pointer;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.speech-demo-card:hover,
.speech-demo-card:focus-visible {
    transform: translateY(-2px);
    box-shadow: 0 0.5rem 1.25rem rgba(30, 27, 75, 0.12);
    outline: none;
}

.speech-demo-card-badge {
    display: inline-block;
    margin-bottom: 0.65rem;
    padding: 0.2rem 0.55rem;
    border-radius: 999px;
    background: hsl(var(--speech-hue, 280), 70%, 94%);
    color: hsl(var(--speech-hue, 280), 45%, 32%);
    font-size: 0.78rem;
    font-weight: 700;
}

.speech-demo-card-title {
    margin: 0 0 0.5rem;
    font-size: 1.08rem;
    font-weight: 700;
    color: var(--ks-accent-deep, var(--tts-accent-deep, #311b92));
    overflow-wrap: anywhere;
    word-break: break-word;
}

.speech-demo-card-text {
    margin: 0 0 0.85rem;
    flex: 1 1 auto;
    color: #334155;
    line-height: 1.5;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.speech-demo-card-action {
    font-weight: 700;
    color: #4c1d95;
}

/* SiteSettings hero- og innholdstema (samme paletter som MatchMate) */
.speech-hero-media.tts-hero__theme--purple,
.speech-page__media.tts-hero__theme--purple {
    background:
        linear-gradient(135deg, rgba(69, 39, 160, 0.25) 0%, rgba(49, 27, 146, 0.72) 100%),
        linear-gradient(145deg, #311b92 0%, #4527a0 35%, #673ab7 60%, #512da8 100%);
}

.speech-hero-media.tts-hero__theme--purple::after,
.speech-page__media.tts-hero__theme--purple::after {
    background:
        radial-gradient(circle at 15% 85%, rgba(179, 157, 219, 0.28) 0%, transparent 45%),
        radial-gradient(circle at 85% 15%, rgba(126, 87, 194, 0.22) 0%, transparent 40%);
}

.speech-hero-media.tts-hero__theme--blue,
.speech-page__media.tts-hero__theme--blue {
    background:
        linear-gradient(135deg, rgba(13, 71, 161, 0.25) 0%, rgba(21, 101, 192, 0.72) 100%),
        linear-gradient(145deg, #0d47a1 0%, #1565c0 35%, #1976d2 60%, #1e88e5 100%);
}

.speech-hero-media.tts-hero__theme--blue::after,
.speech-page__media.tts-hero__theme--blue::after {
    background:
        radial-gradient(circle at 15% 85%, rgba(144, 202, 249, 0.28) 0%, transparent 45%),
        radial-gradient(circle at 85% 15%, rgba(100, 181, 246, 0.22) 0%, transparent 40%);
}

.speech-hero-media.tts-hero__theme--teal,
.speech-page__media.tts-hero__theme--teal {
    background:
        linear-gradient(135deg, rgba(0, 77, 64, 0.25) 0%, rgba(0, 105, 92, 0.72) 100%),
        linear-gradient(145deg, #004d40 0%, #00695c 35%, #00897b 60%, #26a69a 100%);
}

.speech-hero-media.tts-hero__theme--teal::after,
.speech-page__media.tts-hero__theme--teal::after {
    background:
        radial-gradient(circle at 15% 85%, rgba(128, 203, 196, 0.28) 0%, transparent 45%),
        radial-gradient(circle at 85% 15%, rgba(77, 182, 172, 0.22) 0%, transparent 40%);
}

.speech-hero-media.tts-hero__theme--green,
.speech-page__media.tts-hero__theme--green {
    background:
        linear-gradient(135deg, rgba(27, 94, 32, 0.25) 0%, rgba(46, 125, 50, 0.72) 100%),
        linear-gradient(145deg, #1b5e20 0%, #2e7d32 35%, #388e3c 60%, #43a047 100%);
}

.speech-hero-media.tts-hero__theme--green::after,
.speech-page__media.tts-hero__theme--green::after {
    background:
        radial-gradient(circle at 15% 85%, rgba(165, 214, 167, 0.28) 0%, transparent 45%),
        radial-gradient(circle at 85% 15%, rgba(129, 199, 132, 0.22) 0%, transparent 40%);
}

.speech-hero-media.tts-hero__theme--rose,
.speech-page__media.tts-hero__theme--rose {
    background:
        linear-gradient(135deg, rgba(136, 14, 79, 0.25) 0%, rgba(173, 20, 87, 0.72) 100%),
        linear-gradient(145deg, #880e4f 0%, #ad1457 35%, #c2185b 60%, #d81b60 100%);
}

.speech-hero-media.tts-hero__theme--rose::after,
.speech-page__media.tts-hero__theme--rose::after {
    background:
        radial-gradient(circle at 15% 85%, rgba(244, 143, 177, 0.28) 0%, transparent 45%),
        radial-gradient(circle at 85% 15%, rgba(236, 64, 122, 0.22) 0%, transparent 40%);
}

.speech-hero-media.tts-hero__theme--slate,
.speech-page__media.tts-hero__theme--slate {
    background:
        linear-gradient(135deg, rgba(38, 50, 56, 0.25) 0%, rgba(55, 71, 79, 0.72) 100%),
        linear-gradient(145deg, #263238 0%, #37474f 35%, #455a64 60%, #546e7a 100%);
}

.speech-hero-media.tts-hero__theme--slate::after,
.speech-page__media.tts-hero__theme--slate::after {
    background:
        radial-gradient(circle at 15% 85%, rgba(176, 190, 197, 0.28) 0%, transparent 45%),
        radial-gradient(circle at 85% 15%, rgba(144, 164, 174, 0.22) 0%, transparent 40%);
}

.speech-hero-media.tts-hero__theme--lightblue,
.speech-page__media.tts-hero__theme--lightblue {
    background:
        linear-gradient(135deg, rgba(227, 242, 253, 0.95) 0%, rgba(144, 202, 249, 0.88) 100%),
        linear-gradient(145deg, #e3f2fd 0%, #bbdefb 35%, #90caf9 60%, #64b5f6 100%);
}

.speech-hero-media.tts-hero__theme--lightblue::after,
.speech-page__media.tts-hero__theme--lightblue::after {
    background:
        radial-gradient(circle at 15% 85%, rgba(255, 255, 255, 0.55) 0%, transparent 45%),
        radial-gradient(circle at 85% 15%, rgba(25, 118, 210, 0.12) 0%, transparent 40%);
}

.speech-hero-media.tts-hero__theme--lightgray,
.speech-page__media.tts-hero__theme--lightgray {
    background:
        linear-gradient(135deg, rgba(250, 250, 250, 0.98) 0%, rgba(207, 216, 220, 0.88) 100%),
        linear-gradient(145deg, #fafafa 0%, #eceff1 35%, #cfd8dc 60%, #b0bec5 100%);
}

.speech-hero-media.tts-hero__theme--lightgray::after,
.speech-page__media.tts-hero__theme--lightgray::after {
    background:
        radial-gradient(circle at 15% 85%, rgba(255, 255, 255, 0.65) 0%, transparent 45%),
        radial-gradient(circle at 85% 15%, rgba(96, 125, 139, 0.1) 0%, transparent 40%);
}

.speech-hero-media.tts-hero__theme--lightgreen,
.speech-page__media.tts-hero__theme--lightgreen {
    background:
        linear-gradient(135deg, rgba(232, 245, 233, 0.95) 0%, rgba(165, 214, 167, 0.88) 100%),
        linear-gradient(145deg, #e8f5e9 0%, #c8e6c9 35%, #a5d6a7 60%, #81c784 100%);
}

.speech-hero-media.tts-hero__theme--lightgreen::after,
.speech-page__media.tts-hero__theme--lightgreen::after {
    background:
        radial-gradient(circle at 15% 85%, rgba(255, 255, 255, 0.55) 0%, transparent 45%),
        radial-gradient(circle at 85% 15%, rgba(56, 142, 60, 0.1) 0%, transparent 40%);
}

.speech-hero-media.tts-hero__theme--lightlavender,
.speech-page__media.tts-hero__theme--lightlavender {
    background:
        linear-gradient(135deg, rgba(243, 229, 245, 0.95) 0%, rgba(206, 147, 216, 0.85) 100%),
        linear-gradient(145deg, #f3e5f5 0%, #e1bee7 35%, #ce93d8 60%, #ba68c8 100%);
}

.speech-hero-media.tts-hero__theme--lightlavender::after,
.speech-page__media.tts-hero__theme--lightlavender::after {
    background:
        radial-gradient(circle at 15% 85%, rgba(255, 255, 255, 0.55) 0%, transparent 45%),
        radial-gradient(circle at 85% 15%, rgba(106, 27, 154, 0.1) 0%, transparent 40%);
}

.speech-hero:has(.tts-hero__theme--lightblue, .tts-hero__theme--lightgray, .tts-hero__theme--lightgreen, .tts-hero__theme--lightlavender) {
    color: #202124;
    --speech-hero-btn-secondary-bg: var(--tts-btn-secondary-bg, rgba(255, 255, 255, 0.88));
    --speech-hero-btn-secondary-border: var(--tts-btn-secondary-border, rgba(32, 33, 36, 0.24));
    --speech-hero-btn-secondary-text: var(--tts-btn-secondary-text, #202124);
    --speech-hero-btn-secondary-hover-bg: var(--tts-btn-secondary-hover-bg, rgba(32, 33, 36, 0.08));
    --speech-hero-btn-secondary-hover-text: var(--tts-btn-secondary-text-hover, #202124);
    --speech-hero-btn-outline-bg: var(--tts-btn-secondary-bg, rgba(255, 255, 255, 0.88));
    --speech-hero-btn-outline-border: var(--tts-btn-secondary-border, rgba(32, 33, 36, 0.24));
    --speech-hero-btn-outline-text: var(--tts-btn-secondary-text, #202124);
    --speech-hero-btn-outline-hover-bg: var(--tts-btn-secondary-hover-bg, rgba(32, 33, 36, 0.08));
    --speech-hero-btn-outline-hover-border: var(--tts-btn-secondary-border-hover, rgba(32, 33, 36, 0.4));
    --speech-hero-btn-outline-hover-text: var(--tts-btn-secondary-text-hover, #202124);
    --speech-hero-btn-host-border: rgba(180, 83, 9, 0.45);
    --speech-hero-btn-host-hover-border: rgba(180, 83, 9, 0.7);
}

.speech-hero:has(.tts-hero__theme--lightblue, .tts-hero__theme--lightgray, .tts-hero__theme--lightgreen, .tts-hero__theme--lightlavender) .speech-hero-overlay {
    background: linear-gradient(to top, rgba(255, 255, 255, 0.92) 0%, rgba(255, 255, 255, 0.45) 70%, transparent 100%);
    color: #202124;
}

.speech-hero:has(.tts-hero__theme--lightblue, .tts-hero__theme--lightgray, .tts-hero__theme--lightgreen, .tts-hero__theme--lightlavender) .speech-hero-title,
.speech-hero:has(.tts-hero__theme--lightblue, .tts-hero__theme--lightgray, .tts-hero__theme--lightgreen, .tts-hero__theme--lightlavender) .speech-hero-sub {
    color: #202124;
}

.speech-inspiration:has(.tts-hero__theme--lightblue, .tts-hero__theme--lightgray, .tts-hero__theme--lightgreen, .tts-hero__theme--lightlavender) {
    color: #202124;
}

.speech-inspiration:has(.tts-hero__theme--lightblue, .tts-hero__theme--lightgray, .tts-hero__theme--lightgreen, .tts-hero__theme--lightlavender) .speech-inspiration-title,
.speech-inspiration:has(.tts-hero__theme--lightblue, .tts-hero__theme--lightgray, .tts-hero__theme--lightgreen, .tts-hero__theme--lightlavender) .speech-carousel-caption,
.speech-inspiration:has(.tts-hero__theme--lightblue, .tts-hero__theme--lightgray, .tts-hero__theme--lightgreen, .tts-hero__theme--lightlavender) .speech-carousel-caption h3,
.speech-inspiration:has(.tts-hero__theme--lightblue, .tts-hero__theme--lightgray, .tts-hero__theme--lightgreen, .tts-hero__theme--lightlavender) .speech-carousel-caption p {
    color: #202124;
}

.speech-inspiration:has(.tts-hero__theme--lightblue, .tts-hero__theme--lightgray, .tts-hero__theme--lightgreen, .tts-hero__theme--lightlavender) .speech-carousel-slide--themed {
    background: rgba(255, 255, 255, 0.45);
    border-color: rgba(32, 33, 36, 0.12);
}

@media (min-width: 768px) {
    .speech-module,
    .speech-module.speech-module--landing {
        width: 100%;
        max-width: 100%;
        margin-left: 0;
        margin-right: 0;
    }

    .speech-module.speech-module--landing {
        --speech-gutter: 0.75rem;
        padding: var(--speech-landing-inset);
        padding-bottom: 2rem;
    }

    .speech-module--landing .speech-page-part {
        border-radius: 0.75rem;
    }

    .speech-module--landing .speech-landing-content,
    .speech-module--landing .speech-page-body {
        --speech-page-body-inset: 0.75rem;
        border-radius: 0.75rem;
    }

    .speech-module--landing .speech-landing-content .speech-section,
    .speech-module--landing .speech-page-body .speech-panel,
    .speech-module--landing .speech-page-body .speech-auth-notice,
    .speech-module--landing .speech-footer {
        padding: 1.5rem 1.35rem;
    }
}

@media (max-width: 576px) {
    .speech-module.speech-module--landing {
        --speech-landing-inset: 0.35rem;
        margin-top: 0.15rem;
        padding: var(--speech-landing-inset);
        padding-bottom: 1.25rem;
        gap: var(--speech-landing-inset);
        border-radius: 0.85rem;
    }

    .speech-module--landing .speech-page-part {
        border-radius: 0.5rem;
    }

    .speech-inspiration-overlay {
        padding-block: 0.95rem 1.05rem;
    }
}

@media (max-width: 768px) {
    .speech-hero:not(.speech-hero--compact) {
        min-height: 180px;
    }

    .speech-hero-figure {
        max-width: min(140px, 34vw);
        max-height: min(120px, 28vh);
        opacity: 0.85;
    }
}

.speech-landing-balance {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 0.75rem;
}

.speech-landing-balance .ks-balance-bar--embedded {
    justify-content: flex-end;
}
