@charset "UTF-8";

/* DRAMORY webtoon corner. List and series pages load this after agency.css;
   the viewer loads it alone. */

/* Author display rules below must not revive elements the script hides. */
.wt-page [hidden],
.wt-viewer [hidden] {
  display: none !important;
}

/* ---------- list & series pages ---------- */
.wt-page .button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 22px;
  border: 1px solid var(--ink);
  font-size: 13px;
}

.wt-page .button.solid {
  background: var(--ink);
  color: var(--paper);
}

.wt-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 48px 28px;
  padding-top: 20px;
}

.wt-card {
  display: block;
}

.wt-cover {
  overflow: hidden;
  aspect-ratio: 3 / 4;
  background: #d9d6cd;
}

.wt-cover img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .5s;
}

.wt-card:hover .wt-cover img {
  transform: scale(1.03);
}

.wt-card-body {
  padding-top: 18px;
}

.wt-card-body .label {
  margin: 0 0 8px;
  opacity: .7;
}

.wt-card-body h3 {
  margin: 0 0 10px;
  font-size: 23px;
  line-height: 1.35;
}

.wt-card-body p {
  margin: 0 0 12px;
  font-size: 14px;
  line-height: 1.7;
}

.wt-card-meta {
  color: var(--muted);
  font-size: 12px;
}

.wt-ep-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 30px 24px;
  padding-top: 6px;
}

.wt-ep-card {
  display: block;
}

.wt-ep-art {
  overflow: hidden;
  aspect-ratio: 4 / 3;
  background: #d9d6cd;
}

.wt-ep-art img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .5s;
}

.wt-ep-card:hover .wt-ep-art img {
  transform: scale(1.03);
}

.wt-ep-body {
  padding-top: 15px;
}

.wt-ep-body .label {
  margin: 0 0 8px;
  opacity: .7;
}

.wt-ep-body h3 {
  margin: 0 0 8px;
  font-size: 20px;
}

.wt-ep-body p {
  display: -webkit-box;
  overflow: hidden;
  margin: 0 0 10px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  font-size: 14px;
  line-height: 1.7;
}

.wt-empty {
  padding: 70px 24px;
  border: 1px solid var(--line);
  text-align: center;
}

.wt-empty h2 {
  margin: 0 0 12px;
  font-size: 26px;
}

.wt-empty p {
  margin: 0;
  color: var(--muted);
}

.wt-hero {
  display: grid;
  grid-template-columns: minmax(220px, 360px) minmax(0, 1fr);
  gap: 56px;
  align-items: start;
}

.wt-hero-cover img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  background: #d9d6cd;
}

.wt-hero-copy .back {
  display: inline-block;
  margin-bottom: 28px;
  font-size: 12px;
}

.wt-hero-copy h1 {
  margin: 14px 0 6px;
  font-size: clamp(34px, 4.4vw, 64px);
  line-height: 1.15;
}

.wt-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 22px 0;
}

.wt-badge {
  padding: 5px 11px;
  border: 1px solid var(--line);
  border-radius: 99px;
  font-size: 12px;
}

.wt-logline {
  max-width: 36em;
  margin: 0 0 26px;
  font-size: 17px;
  line-height: 1.75;
}

.wt-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 24px;
  max-width: 560px;
  margin: 0 0 30px;
}

.wt-facts div {
  padding: 12px 0;
  border-top: 1px solid var(--line);
}

.wt-facts dt {
  color: var(--muted);
  font-size: 10px;
  letter-spacing: 1.4px;
}

.wt-facts dd {
  margin: 4px 0 0;
  font-size: 14px;
}

.wt-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.wt-section {
  padding-top: 0;
}

.wt-section h2 {
  margin: 10px 0 24px;
  font-size: 30px;
}

.wt-synopsis {
  max-width: 820px;
  font-size: 16px;
  line-height: 1.9;
}

.wt-cast {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.wt-cast a {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 150px;
  padding: 14px 18px;
  border: 1px solid var(--line);
}

.wt-cast span {
  color: var(--muted);
  font-size: 12px;
}

.wt-cast strong {
  font-size: 16px;
  font-weight: 500;
}

.wt-cast a:hover {
  border-color: var(--ink);
}

.wt-related a {
  font-size: 18px;
  text-decoration: underline;
  text-underline-offset: 5px;
}

.wt-list-head {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
}

.wt-sort {
  display: flex;
  gap: 6px;
  margin-bottom: 24px;
}

.wt-sort button {
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid var(--line);
  background: none;
  cursor: pointer;
  font-size: 12px;
}

.wt-sort button[aria-pressed="true"] {
  border-color: var(--ink);
  background: var(--ink);
  color: var(--paper);
}

.wt-episodes {
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--line);
  list-style: none;
}

.wt-episodes.desc {
  flex-direction: column-reverse;
}

.wt-episodes a {
  display: grid;
  grid-template-columns: 128px auto minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 18px;
  min-height: 96px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}

.wt-episodes img {
  display: block;
  width: 128px;
  height: 96px;
  object-fit: cover;
  background: #d9d6cd;
}

.wt-ep-no {
  color: var(--muted);
  font-size: 13px;
  white-space: nowrap;
}

.wt-ep-title {
  font-size: 16px;
}

.wt-ep-date {
  color: var(--muted);
  font-size: 12px;
}

.wt-ep-read {
  padding: 3px 8px;
  background: var(--acid);
  font-size: 11px;
}

.wt-episodes a:hover .wt-ep-title {
  text-decoration: underline;
  text-underline-offset: 4px;
}

@media (max-width: 760px) {
  .wt-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 34px 14px;
  }

  .wt-card-body h3 {
    font-size: 18px;
  }

  .wt-card-body p {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    font-size: 13px;
  }

  .wt-ep-grid {
    grid-template-columns: 1fr;
    gap: 26px;
  }

  .wt-hero {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .wt-hero-cover {
    max-width: 300px;
  }

  .wt-actions .button {
    flex: 1 1 100%;
  }

  .wt-episodes a {
    grid-template-columns: 96px minmax(0, 1fr) auto;
    grid-template-areas: "thumb no read" "thumb title title" "thumb date date";
    gap: 2px 14px;
  }

  .wt-episodes img {
    grid-area: thumb;
    width: 96px;
    height: 72px;
  }

  .wt-ep-no { grid-area: no; }
  .wt-ep-title { grid-area: title; font-size: 15px; }
  .wt-ep-date { grid-area: date; }
  .wt-ep-read { grid-area: read; justify-self: end; }
}

/* ---------- viewer ---------- */
.wt-viewer {
  --bar: 56px;
  --strip-width: 720px;
  margin: 0;
  background: #101211;
  color: #eceee9;
  font-family: 'Helvetica Neue', Arial, 'Apple SD Gothic Neo', 'Malgun Gothic', sans-serif;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}

.wt-viewer a {
  color: inherit;
  text-decoration: none;
}

.wt-viewer .skip {
  position: absolute;
  top: -80px;
  left: 16px;
  z-index: 30;
  padding: 14px;
  background: #eceee9;
  color: #101211;
}

.wt-viewer .skip:focus {
  top: 10px;
}

.wt-viewer :focus-visible {
  outline: 2px solid #d4e78d;
  outline-offset: 3px;
}

.wt-bar {
  position: fixed;
  right: 0;
  left: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  background: rgba(16, 18, 17, .9);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  transition: transform .25s ease;
}

.wt-top {
  top: 0;
  gap: 6px;
  height: calc(var(--bar) + env(safe-area-inset-top));
  padding: env(safe-area-inset-top) max(10px, env(safe-area-inset-right)) 0 max(6px, env(safe-area-inset-left));
  border-bottom: 1px solid #262a27;
}

.wt-bottom {
  bottom: 0;
  justify-content: space-between;
  height: calc(60px + env(safe-area-inset-bottom));
  padding: 0 max(8px, env(safe-area-inset-right)) env(safe-area-inset-bottom) max(8px, env(safe-area-inset-left));
  border-top: 1px solid #262a27;
}

.wt-hidden .wt-top {
  transform: translateY(-100%);
}

.wt-hidden .wt-bottom {
  transform: translateY(100%);
}

.wt-icon {
  display: grid;
  flex: 0 0 44px;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 0;
  background: none;
  color: inherit;
  cursor: pointer;
  font-size: 26px;
}

.wt-width {
  display: none;
  font-size: 18px;
}

.wt-titles {
  flex: 1 1 auto;
  min-width: 0;
  line-height: 1.25;
}

.wt-titles a {
  display: block;
  overflow: hidden;
  color: #9ba39a;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.wt-titles h1 {
  overflow: hidden;
  margin: 2px 0 0;
  font-size: 15px;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.wt-logo {
  padding: 0 6px;
  font-size: 12px;
  letter-spacing: .5px;
}

.wt-progress {
  position: absolute;
  right: 0;
  bottom: -1px;
  left: 0;
  height: 2px;
}

.wt-progress span {
  display: block;
  width: 100%;
  height: 100%;
  background: #d4e78d;
  transform: scaleX(0);
  transform-origin: left;
}

.wt-strip {
  width: 100%;
  max-width: var(--strip-width);
  margin: 0 auto;
  padding-top: calc(var(--bar) + env(safe-area-inset-top));
  outline: none;
}

.wt-strip img {
  display: block;
  width: 100%;
  height: auto;
  -webkit-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
}

.wt-end {
  max-width: var(--strip-width);
  margin: 0 auto;
  padding: 44px 18px calc(110px + env(safe-area-inset-bottom));
  text-align: center;
}

.wt-end-title {
  margin: 0 0 26px;
  color: #9ba39a;
  font-size: 14px;
}

.wt-next-card {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr) 24px;
  align-items: center;
  gap: 16px;
  padding: 12px;
  border: 1px solid #2d322e;
  background: #171a18;
  text-align: left;
}

.wt-next-card img {
  width: 112px;
  height: 84px;
  object-fit: cover;
}

.wt-next-card small {
  display: block;
  margin-bottom: 4px;
  color: #d4e78d;
  font-size: 11px;
}

.wt-next-card strong {
  font-size: 16px;
  line-height: 1.4;
}

.wt-next-card b {
  font-size: 26px;
  font-weight: 300;
}

.wt-end-note {
  margin: 0;
  line-height: 1.7;
}

.wt-end-list {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  margin-top: 18px;
  color: #9ba39a !important;
  font-size: 13px;
  text-decoration: underline !important;
  text-underline-offset: 4px;
}

.wt-bottom > a,
.wt-bottom > span {
  display: flex;
  flex: 1 1 0;
  align-items: center;
  justify-content: center;
  height: 48px;
  font-size: 14px;
}

.wt-bottom > span[aria-disabled] {
  color: #555c56;
}

.wt-nav-list {
  max-width: 120px;
  border-right: 1px solid #262a27;
  border-left: 1px solid #262a27;
}

.wt-resume {
  position: fixed;
  bottom: calc(76px + env(safe-area-inset-bottom));
  left: 50%;
  z-index: 25;
  display: flex;
  align-items: center;
  gap: 8px;
  max-width: calc(100% - 24px);
  padding: 8px 8px 8px 16px;
  border: 1px solid #2d322e;
  border-radius: 99px;
  background: #1b1f1c;
  font-size: 13px;
  white-space: nowrap;
  transform: translateX(-50%);
}

.wt-resume button {
  min-height: 36px;
  padding: 0 14px;
  border: 0;
  border-radius: 99px;
  background: #d4e78d;
  color: #101211;
  cursor: pointer;
  font: inherit;
}

.wt-resume [data-dismiss] {
  background: none;
  color: #9ba39a;
}

@media (min-width: 900px) {
  .wt-viewer {
    --bar: 60px;
  }

  .wt-width:not([hidden]) {
    display: grid;
  }

  .wt-bottom {
    right: 50%;
    left: auto;
    width: min(560px, 100%);
    border: 1px solid #262a27;
    border-bottom: 0;
    border-radius: 12px 12px 0 0;
    transform: translateX(50%);
  }

  .wt-hidden .wt-bottom {
    transform: translate(50%, 100%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .wt-bar,
  .wt-cover img {
    transition: none;
  }
}
