@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

:root {
   --awb-bg: #0d1117;
   --awb-bg-gradient: linear-gradient(145deg, #0d1117 0%, #101820 50%, #0d1117 100%);
   --awb-glass: rgba(22, 33, 46, .65);
   --awb-glass-border: rgba(255, 255, 255, .06);
   --awb-text: #e6edf3;
   --awb-text-dim: #7d8590;
   --awb-teal: #3fb9a7;
   --awb-teal-glow: rgba(63, 185, 167, .2);
   --awb-blue: #58a6ff;
   --awb-purple: #bc8cff;
   --awb-red: #f85149;
   --awb-orange: #f0883e;
   --awb-green: #2ea44f;
   --awb-green-glow: rgba(46, 164, 79, .25);
   --awb-r: 16px;
   --awb-r-sm: 10px;
}

/* ── Reset ── */

body.awb-fullscreen {
   margin: 0;
   padding: 0;
   background: var(--awb-bg);
   overflow-x: hidden;
}

body.awb-fullscreen #masthead,
body.awb-fullscreen #site-header,
body.awb-fullscreen .site-header,
body.awb-fullscreen header,
body.awb-fullscreen #colophon,
body.awb-fullscreen #site-footer,
body.awb-fullscreen .site-footer,
body.awb-fullscreen footer,
body.awb-fullscreen .elementor-location-header,
body.awb-fullscreen .elementor-location-footer,
body.awb-fullscreen #wpadminbar {
   display: none !important;
}

/* ── Base ── */

.awb-wrap {
   font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
   color: var(--awb-text);
   background: var(--awb-bg-gradient);
   min-height: 100vh;
   -webkit-font-smoothing: antialiased;
}

/* ── Room layout ── */

.awb-room {
   max-width: 1440px;
   margin: 0 auto;
   padding: 20px;
   box-sizing: border-box;
}

.awb-room-body {
   display: flex;
   gap: 16px;
   align-items: stretch;
   height: calc(100vh - 40px);
   min-height: 400px;
   overflow: hidden;
}

/* ── Video ── */

.awb-video-col {
   flex: 1;
   min-width: 0;
   min-height: 0;
   display: flex;
   flex-direction: column;
   gap: 14px;
   overflow: hidden;
}

.awb-video-container {
   position: relative;
   background: #000;
   border-radius: var(--awb-r);
   overflow: hidden;
   aspect-ratio: 16 / 9;
}

.awb-video {
   width: 100%;
   height: 100%;
   object-fit: contain;
   display: block;
}

.awb-video-top {
   position: absolute;
   top: 0;
   left: 0;
   right: 0;
   display: flex;
   align-items: center;
   gap: 12px;
   padding: 16px 20px;
   background: linear-gradient(180deg, rgba(0, 0, 0, .55) 0%, transparent 100%);
   z-index: 2;
   pointer-events: none;
}

.awb-live-badge {
   display: inline-flex;
   align-items: center;
   gap: 6px;
   background: var(--awb-red);
   color: #fff;
   font-size: 10px;
   font-weight: 700;
   padding: 4px 10px;
   border-radius: 6px;
   letter-spacing: .8px;
   text-transform: uppercase;
}

.awb-live-dot {
   width: 6px;
   height: 6px;
   background: #fff;
   border-radius: 50%;
   animation: awb-blink 1.4s ease-in-out infinite;
}

@keyframes awb-blink {

   0%,
   100% {
      opacity: 1;
   }

   50% {
      opacity: .25;
   }
}

.awb-video-title {
   font-size: 14px;
   font-weight: 500;
   color: rgba(255, 255, 255, .8);
   white-space: nowrap;
   overflow: hidden;
   text-overflow: ellipsis;
}

.awb-video-controls {
   position: absolute;
   bottom: 0;
   left: 0;
   right: 0;
   display: flex;
   align-items: center;
   gap: 6px;
   padding: 20px;
   background: linear-gradient(0deg, rgba(0, 0, 0, .6) 0%, transparent 100%);
   opacity: 0;
   transition: opacity .3s;
   z-index: 2;
}

.awb-video-container:hover .awb-video-controls {
   opacity: 1;
}

.awb-ctrl-btn {
   display: flex;
   align-items: center;
   justify-content: center;
   width: 42px;
   height: 42px;
   border: 1px solid rgba(255, 255, 255, .12) !important;
   border-radius: 50%;
   background: rgba(255, 255, 255, .08) !important;
   color: #fff !important;
   cursor: pointer;
   backdrop-filter: blur(16px);
   -webkit-backdrop-filter: blur(16px);
   transition: background .2s, transform .15s, border-color .2s;
}

.awb-ctrl-btn:hover {
   background: rgba(255, 255, 255, .16) !important;
   border-color: rgba(255, 255, 255, .2) !important;
   transform: scale(1.06);
}

.awb-pause-btn .awb-icon-play {
   display: none;
}

.awb-pause-btn.is-paused .awb-icon-pause {
   display: none;
}

.awb-pause-btn.is-paused .awb-icon-play {
   display: block;
}

.awb-mute-btn .awb-icon-muted {
   display: none;
}

.awb-mute-btn.is-muted .awb-icon-unmuted {
   display: none;
}

.awb-mute-btn.is-muted .awb-icon-muted {
   display: block;
}

/* play overlay */

.awb-play-overlay {
   position: absolute;
   inset: 0;
   background: rgba(0, 0, 0, .45);
   display: flex;
   align-items: center;
   justify-content: center;
   backdrop-filter: blur(8px);
   -webkit-backdrop-filter: blur(8px);
   z-index: 5;
}

/* countdown overlay */

.awb-countdown-overlay {
   position: absolute;
   inset: 0;
   background: linear-gradient(145deg, #0d1117 0%, #131d29 50%, #0d1117 100%);
   display: flex;
   align-items: center;
   justify-content: center;
   z-index: 6;
   border-radius: var(--awb-r);
}

.awb-countdown-inner {
   text-align: center;
}

.awb-countdown-label {
   font-size: 16px;
   font-weight: 500;
   color: var(--awb-text-dim);
   margin-bottom: 16px;
   letter-spacing: .3px;
}

.awb-countdown-timer {
   font-size: 64px;
   font-weight: 700;
   color: var(--awb-text);
   letter-spacing: 4px;
   font-variant-numeric: tabular-nums;
}

/* grace overlay */

.awb-grace-overlay {
   position: absolute;
   inset: 0;
   background: linear-gradient(145deg, #0d1117 0%, #131d29 50%, #0d1117 100%);
   display: flex;
   align-items: center;
   justify-content: center;
   z-index: 6;
   border-radius: var(--awb-r);
}

.awb-grace-inner {
   text-align: center;
}

.awb-grace-label {
   font-size: 24px;
   font-weight: 600;
   color: var(--awb-text);
}

/* finished overlay (end of day) */

.awb-finished-overlay {
   position: absolute;
   inset: 0;
   background: linear-gradient(145deg, #0d1117 0%, #131d29 50%, #0d1117 100%);
   display: flex;
   align-items: center;
   justify-content: center;
   z-index: 6;
   border-radius: var(--awb-r);
}

.awb-finished-inner {
   text-align: center;
}

.awb-finished-label {
   font-size: 22px;
   font-weight: 600;
   color: var(--awb-text);
   margin-bottom: 8px;
}

.awb-finished-sub {
   font-size: 15px;
   color: var(--awb-text-dim);
}

/* chat locked */

.awb-chat-col.is-chat-locked .awb-chat-messages::after {
   content: 'Чат откроется перед эфиром';
   display: flex;
   align-items: center;
   justify-content: center;
   position: absolute;
   inset: 0;
   font-size: 13px;
   color: var(--awb-text-dim);
   background: var(--awb-glass);
}

.awb-chat-col.is-chat-locked .awb-chat-messages {
   position: relative;
}

.awb-chat-input-wrap.is-disabled {
   opacity: .4;
   pointer-events: none;
}

.awb-overlay-btn {
   width: 84px;
   height: 84px;
   border: 2px solid rgba(255, 255, 255, .15);
   border-radius: 50%;
   background: rgba(255, 255, 255, .06);
   color: #fff;
   cursor: pointer;
   display: flex;
   align-items: center;
   justify-content: center;
   backdrop-filter: blur(20px);
   -webkit-backdrop-filter: blur(20px);
   transition: background .2s, transform .2s, border-color .2s;
}

.awb-overlay-btn:hover {
   background: rgba(255, 255, 255, .12);
   border-color: rgba(255, 255, 255, .3);
   transform: scale(1.06);
}

/* ── Action button ── */

.awb-action-btn-wrap {
   text-align: center;
}

.awb-action-btn {
   display: inline-block;
   padding: 14px 40px;
   font-size: 15px;
   font-weight: 600;
   font-family: inherit;
   color: #fff !important;
   background: var(--awb-green);
   border: none;
   border-radius: var(--awb-r-sm);
   cursor: pointer;
   text-decoration: none;
   box-shadow: 0 0 24px var(--awb-green-glow);
   transition: filter .15s, box-shadow .15s;
}

.awb-action-btn:hover {
   filter: brightness(1.15);
   box-shadow: 0 0 36px var(--awb-green-glow);
}

/* ── Chat ── */

.awb-chat-col {
   width: 340px;
   flex-shrink: 0;
   min-height: 0;
   display: flex;
   flex-direction: column;
   background: var(--awb-glass);
   border: 1px solid var(--awb-glass-border);
   border-radius: var(--awb-r);
   overflow: hidden;
   backdrop-filter: blur(24px);
   -webkit-backdrop-filter: blur(24px);
}

.awb-chat-header {
   padding: 16px 18px;
   font-weight: 600;
   font-size: 12px;
   color: var(--awb-text-dim);
   text-transform: uppercase;
   letter-spacing: .8px;
   border-bottom: 1px solid var(--awb-glass-border);
   display: flex;
   align-items: center;
   gap: 8px;
}

.awb-chat-messages {
   flex: 1;
   overflow-y: auto;
   padding: 10px;
   display: flex;
   flex-direction: column;
   gap: 4px;
}

.awb-chat-messages::-webkit-scrollbar {
   width: 3px;
}

.awb-chat-messages::-webkit-scrollbar-track {
   background: transparent;
}

.awb-chat-messages::-webkit-scrollbar-thumb {
   background: rgba(255, 255, 255, .06);
   border-radius: 3px;
}

.awb-chat-msg {
   display: flex;
   flex-direction: column;
   gap: 3px;
   font-size: 13px;
   line-height: 1.5;
   padding: 8px 12px;
   border-radius: 12px;
   background: rgba(255, 255, 255, .04);
   border: 1px solid transparent;
}

.awb-chat-author {
   font-weight: 600;
   font-size: 12px;
   display: block;
}

.awb-chat-text {
   color: var(--awb-text);
   display: block;
   word-break: break-word;
}

/* Reply-цитата (как в Telegram) */

.awb-chat-reply {
   display: flex;
   flex-direction: column;
   gap: 1px;
   padding: 4px 8px;
   border-left: 3px solid var(--awb-purple);
   background: rgba(188, 140, 255, .08);
   border-radius: 0 6px 6px 0;
   margin-bottom: 2px;
   overflow: hidden;
}

.awb-chat-reply-author {
   font-size: 11px;
   font-weight: 700;
   color: var(--awb-purple);
   white-space: nowrap;
   overflow: hidden;
   text-overflow: ellipsis;
}

.awb-chat-reply-text {
   font-size: 11px;
   color: var(--awb-text-dim);
   white-space: nowrap;
   overflow: hidden;
   text-overflow: ellipsis;
}

.awb-chat-participant .awb-chat-author {
   color: var(--awb-blue);
}

.awb-chat-question .awb-chat-author {
   color: var(--awb-purple);
}

.awb-chat-answer,
.awb-chat-moderator {
   background: rgba(63, 185, 167, .07);
   border-color: rgba(63, 185, 167, .15);
}

.awb-chat-answer .awb-chat-author,
.awb-chat-moderator .awb-chat-author {
   color: var(--awb-teal);
}

.awb-chat-viewer .awb-chat-author {
   color: var(--awb-orange);
}

.awb-chat-input-wrap {
   display: flex;
   padding: 12px;
   gap: 8px;
   border-top: 1px solid var(--awb-glass-border);
}

.awb-chat-input {
   flex: 1;
   background: rgba(255, 255, 255, .04);
   border: 1px solid rgba(255, 255, 255, .07);
   border-radius: 24px;
   padding: 10px 18px;
   font-size: 13px;
   color: var(--awb-text);
   outline: none;
   font-family: inherit;
   transition: border-color .2s, background .2s;
}

.awb-chat-input::placeholder {
   color: var(--awb-text-dim);
}

.awb-chat-input:focus {
   border-color: var(--awb-teal);
   background: rgba(255, 255, 255, .06);
}

.awb-chat-send {
   display: flex;
   align-items: center;
   justify-content: center;
   width: 40px;
   height: 40px;
   flex-shrink: 0;
   background: var(--awb-teal) !important;
   color: #fff !important;
   border: none !important;
   border-radius: 50%;
   cursor: pointer;
   transition: background .15s, box-shadow .15s, transform .1s;
   box-shadow: 0 0 14px var(--awb-teal-glow);
}

.awb-chat-send:hover {
   background: #4ecfbd;
   box-shadow: 0 0 22px var(--awb-teal-glow);
   transform: scale(1.05);
}

.awb-chat-send:disabled {
   opacity: .3;
   cursor: not-allowed;
   transform: none;
}

/* ── Landing ── */

.awb-landing {
   display: flex;
   flex-direction: column;
   align-items: center;
   justify-content: center;
   min-height: 100vh;
   padding: 40px 20px;
   text-align: center;
}

.awb-landing h1 {
   font-size: 44px;
   font-weight: 700;
   letter-spacing: -.5px;
   margin: 0 0 14px;
   background: linear-gradient(135deg, #e6edf3 30%, var(--awb-teal) 100%);
   -webkit-background-clip: text;
   -webkit-text-fill-color: transparent;
   background-clip: text;
}

.awb-status {
   font-size: 17px;
   color: var(--awb-text-dim);
   margin-bottom: 36px;
}

.awb-btn {
   display: inline-block;
   padding: 16px 48px;
   font-size: 15px;
   font-weight: 600;
   font-family: inherit;
   color: #fff !important;
   background: var(--awb-teal) !important;
   border: none !important;
   border-radius: var(--awb-r-sm);
   cursor: pointer;
   text-decoration: none;
   text-align: center;
   box-shadow: 0 0 28px var(--awb-teal-glow);
   transition: background .15s, box-shadow .15s, transform .1s;
}

.awb-btn:hover {
   background: #4ecfbd !important;
   box-shadow: 0 0 40px var(--awb-teal-glow);
   transform: translateY(-1px);
}

.awb-btn:disabled {
   opacity: .4;
   cursor: not-allowed;
   transform: none;
}

/* ── Modal ── */

.awb-modal {
   position: fixed;
   inset: 0;
   background: rgba(0, 0, 0, .55);
   display: flex;
   align-items: center;
   justify-content: center;
   z-index: 9999;
   backdrop-filter: blur(12px);
   -webkit-backdrop-filter: blur(12px);
}

.awb-modal-content {
   background: var(--awb-glass);
   border: 1px solid var(--awb-glass-border);
   border-radius: var(--awb-r);
   padding: 40px 36px;
   width: 400px;
   max-width: 90vw;
   position: relative;
   backdrop-filter: blur(28px);
   -webkit-backdrop-filter: blur(28px);
   box-shadow: 0 32px 80px rgba(0, 0, 0, .5);
}

.awb-modal-close {
   position: absolute;
   top: 16px;
   right: 20px;
   background: none !important;
   border: none !important;
   font-size: 20px;
   cursor: pointer;
   color: var(--awb-text-dim) !important;
   line-height: 1;
   transition: color .15s;
}

.awb-modal-close:hover {
   color: var(--awb-text) !important;
}

.awb-modal-content h2 {
   margin: 0 0 28px;
   font-size: 22px;
   font-weight: 600;
   color: var(--awb-text);
}

.awb-register-form input {
   display: block;
   width: 100%;
   padding: 14px 18px;
   margin-bottom: 12px;
   font-size: 15px;
   font-family: inherit;
   background: rgba(255, 255, 255, .04);
   border: 1px solid rgba(255, 255, 255, .07);
   border-radius: var(--awb-r-sm);
   color: var(--awb-text);
   box-sizing: border-box;
   outline: none;
   transition: border-color .2s, background .2s;
}

.awb-register-form input::placeholder {
   color: var(--awb-text-dim);
}

.awb-register-form input:focus {
   border-color: var(--awb-teal);
   background: rgba(255, 255, 255, .06);
}

.awb-register-form .awb-btn {
   width: 100%;
   margin-top: 8px;
}

.awb-form-error {
   color: var(--awb-red);
   font-size: 14px;
   margin-top: 12px;
}

/* ── Responsive ── */

/* Если вебинар вставлен через шорткод на странице с темой —
   растягиваем на всю ширину вьюпорта поверх контентной колонки */
.awb-room-wrap {
   position: relative;
   width: 100vw;
   left: 50%;
   right: 50%;
   margin-left: -50vw;
   margin-right: -50vw;
   box-sizing: border-box;
}

@media (max-width: 768px) {
   .awb-room {
      padding: 10px;
   }

   .awb-room-body {
      flex-direction: column;
      height: auto;
      min-height: 0;
      overflow: visible;
   }

   .awb-video-container {
      aspect-ratio: 16 / 9;
      flex: none;
   }

   .awb-chat-col {
      width: 100%;
      height: 360px;
   }

   .awb-landing h1 {
      font-size: 28px;
   }
}