/*==================================================
    Fish Fish - Your Dock
==================================================*/

[data-icon="anchor"] { --icon: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><circle cx='12' cy='5' r='2.2'/><path d='M12 7.2V21'/><path d='M8 11h8'/><path d='M4.5 14.5a7.5 7.5 0 0 0 15 0'/><path d='M3 15.5l1.5-1.5 1.5 1.5M18 15.5l1.5-1.5 1.5 1.5'/></svg>"); }

.dk-modal {
    width: min(1320px, 100%);
}

.dk-modal .book-header {
    align-items: center;
    flex-wrap: wrap;
    gap: 10px 14px;
}

.dk-modal .book-header > div:first-child {
    flex: 1 1 260px;
    min-width: 0;
}

.dk-wallet {
    display: flex;
    gap: 8px;
}

.dk-wallet span,
.dk-pill {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 10px;
    border: 1px solid var(--line);
    border-radius: var(--ff-r-pill, 999px);
    background: rgba(255, 255, 255, 0.05);
    font-weight: 800;
    white-space: nowrap;
}

.dk-pill.lit {
    border-color: rgba(253, 230, 138, 0.6);
    background: rgba(253, 230, 138, 0.14);
    color: #fde68a;
}

.dk-coin {
    display: inline-block;
    width: 13px;
    height: 13px;
    border-radius: 50%;
    background: radial-gradient(circle at 35% 35%, #fff3b0, #facc15 55%, #b45309);
    box-shadow: inset 0 0 0 1px rgba(120, 53, 15, 0.6);
    vertical-align: -2px;
}

.dk-visit-nav {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 3px;
    border: 1px solid var(--line);
    border-radius: var(--ff-r-pill, 999px);
}

.dk-visit-nav button {
    width: 30px;
    height: 30px;
    padding: 0;
    border-radius: 50%;
    font-size: 1.2rem;
    line-height: 1;
}

.dk-visit-nav span {
    min-width: 120px;
    font-weight: 800;
    text-align: center;
}

/* Rail: yellow when a deckhand is free and an upgrade is affordable. */
.ff-rail .ff-dot.dk-upgrade-dot {
    background: #facc15;
    box-shadow: 0 0 0 2px var(--panel-solid), 0 0 8px #facc15;
}

.ff-rail.is-icons .ff-dot.dk-upgrade-dot {
    right: 18px;
}

.ff-rail.is-icons #dockDot[hidden] + .ff-dot.dk-upgrade-dot {
    right: 6px;
}

/* The harbor: an isometric island you can drag and zoom. */
.dk-stage-wrap {
    position: relative;
    height: clamp(440px, 68vh, 780px);
    overflow: hidden;
    border: 1px solid var(--line-strong, var(--line));
    border-radius: var(--ff-r-lg, 18px);
    background: #0b4a68;
}

.dk3-stage {
    position: absolute;
    inset: 0;
    cursor: grab;
    touch-action: none;
}

.dk3-stage.dragging {
    cursor: grabbing;
}

.dk3-svg {
    display: block;
    width: 100%;
    height: 100%;
    user-select: none;
    -webkit-user-select: none;
}

.dk3-zoom {
    position: absolute;
    left: 12px;
    bottom: 12px;
    z-index: 2;
    display: grid;
    gap: 6px;
}

.dk3-zoom button {
    width: 38px;
    height: 38px;
    min-height: 0;
    padding: 0;
    border-radius: 50%;
    background: rgba(8, 22, 34, 0.82);
    font-size: 1.25rem;
    line-height: 1;
}

.dk3-hint {
    position: absolute;
    top: 10px;
    left: 50%;
    z-index: 1;
    padding: 4px 12px;
    border-radius: var(--ff-r-pill, 999px);
    background: rgba(8, 22, 34, 0.7);
    color: #e2e8f0;
    font-size: 0.8rem;
    font-weight: 800;
    white-space: nowrap;
    pointer-events: none;
    transform: translateX(-50%);
}

.dk3-b {
    cursor: pointer;
    outline: none;
}

.dk3-b .dk3-hit {
    fill: transparent;
    stroke: none;
}

.dk3-b .dk3-art {
    transition: filter 0.15s ease;
}

.dk3-b:hover .dk3-art,
.dk3-b:focus-visible .dk3-art {
    filter: brightness(1.12) drop-shadow(0 0 5px rgba(255, 255, 255, 0.55));
}

.dk3-b.selected .dk3-art {
    filter: brightness(1.08) drop-shadow(0 0 8px rgba(253, 230, 138, 0.85));
}

.dk3-b.plot .dk3-art {
    opacity: 0.9;
}

.dk3-b:not(.selected) .dk3-ring {
    display: none;
}

.dk3-badge .dk3-plate {
    display: none;
}

.dk3-badge.plot .dk3-plate,
.dk3-badge.selected .dk3-plate {
    display: inline;
}

.dk3-badge.selected .dk3-lv {
    display: none;
}

/* Every looping animation is offset by --dk3-t, the page clock when its
   layer was drawn, so a redraw resumes mid-loop instead of restarting. */
.dk3-ring,
.dk3-bob,
.dk3-sail,
.dk3-ripples,
.dk3-foam,
.dk3-beam,
.dk3-glow,
.dk3-wave,
.dk3-bubble.ready,
.dk3-bubble.upgrade {
    animation-delay: calc(var(--d, 0s) - var(--dk3-t, 0s)) !important;
}

.dk3-ring {
    fill: rgba(253, 230, 138, 0.16);
    stroke: #fde68a;
    stroke-width: 3;
    stroke-dasharray: 10 6;
    animation: dk3-march 1.2s linear infinite;
}

.dk3-badges {
    pointer-events: none;
}

.dk3-badges text {
    font-family: var(--font-display, sans-serif);
    font-weight: 700;
    text-anchor: middle;
}

.dk3-lv circle {
    fill: #1e293b;
    stroke: #fde68a;
    stroke-width: 2;
}

.dk3-lv text {
    fill: #fde68a;
    font-size: 12px;
}

.dk3-plate rect {
    fill: rgba(15, 23, 42, 0.88);
    stroke: rgba(255, 255, 255, 0.35);
    stroke-width: 1.5;
}

.dk3-badge.selected .dk3-plate rect {
    stroke: #fde68a;
}

.dk3-plate text {
    fill: #f8fafc;
    font-size: 13px;
}

.dk3-plate text.lv {
    fill: #fde68a;
    font-size: 11px;
}

.dk3-bubble.build rect:first-child {
    fill: rgba(15, 23, 42, 0.9);
    stroke: #f59e0b;
    stroke-width: 2;
}

.dk3-bubble.build text {
    fill: #fde68a;
    font-size: 13px;
    font-variant-numeric: tabular-nums;
}

.dk3-bubble.ready {
    animation: dk3-hop 1.4s ease-in-out infinite;
}

.dk3-bubble.ready circle {
    fill: #4ade80;
    stroke: #052e16;
    stroke-width: 2;
}

.dk3-bob {
    animation: dk3-bob 3.4s ease-in-out infinite;
    animation-delay: var(--d, 0s);
}

.dk3-sail {
    transform-box: fill-box;
    transform-origin: center;
    animation: dk3-sail 5s ease-in-out infinite;
    animation-delay: var(--d, 0s);
}

.dk3-ripples {
    animation: dk3-ripple 9s linear infinite;
}

.dk3-foam {
    animation: dk3-foam 3.6s ease-in-out infinite;
}

.dk3-beam {
    animation: dk3-beam 4.5s ease-in-out infinite alternate;
}

.dk3-glow {
    animation: dk3-glow 2.4s ease-in-out infinite;
}

.dk3-wave {
    animation: dk3-wave 4.2s ease-in-out infinite;
    animation-delay: var(--d, 0s);
}

@keyframes dk3-wave {
    0%, 100% { opacity: 0; transform: translateX(-6px); }
    50% { opacity: 1; transform: translateX(6px); }
}

@keyframes dk3-bob {
    50% { transform: translateY(-3px); }
}

@keyframes dk3-hop {
    50% { transform: translateY(-4px); }
}

/* Boats at sea rock on the swell rather than sailing backwards. */
@keyframes dk3-sail {
    0%, 100% { transform: translate(0, 0) rotate(0deg); }
    50% { transform: translate(0, -3px) rotate(-1.5deg); }
}

@keyframes dk3-ripple {
    from { transform: translate(0, 0); }
    to { transform: translate(120px, 60px); }
}

@keyframes dk3-foam {
    50% { opacity: 0.45; }
}

@keyframes dk3-beam {
    from { transform: rotate(-18deg); }
    to { transform: rotate(22deg); }
}

@keyframes dk3-glow {
    50% { opacity: 0.45; }
}

@keyframes dk3-march {
    to { stroke-dashoffset: -16; }
}

/* The building panel, sliding over the harbor. */
.dk-drawer {
    position: absolute;
    top: 12px;
    right: 12px;
    bottom: 12px;
    z-index: 3;
    width: min(470px, calc(100% - 24px));
    overflow-y: auto;
    border: 1px solid var(--line);
    border-radius: var(--ff-r-lg, 18px);
    background: rgba(8, 22, 34, 0.95);
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.5);
    animation: dk3-drawer 0.18s ease-out;
}

.dk-drawer[hidden] {
    display: none;
}

.dk-drawer .dk-detail {
    align-content: start;
    min-height: 100%;
    border-radius: var(--ff-r-lg, 18px);
    border: 0;
}

.dk-drawer .dk-effects {
    grid-template-columns: minmax(0, 1fr);
}

.dk-drawer-close {
    position: sticky;
    top: 8px;
    z-index: 2;
    float: right;
    width: 34px;
    height: 34px;
    min-height: 0;
    margin: 8px 8px -42px 0;
    padding: 0;
    border-radius: 50%;
    font-size: 1.3rem;
    line-height: 1;
}

.dk-drawer.locked {
    top: 50%;
    right: auto;
    bottom: auto;
    left: 50%;
    width: min(760px, calc(100% - 24px));
    max-height: calc(100% - 24px);
    transform: translate(-50%, -50%);
    animation: none;
}

.dk-drawer.locked .dk-locked {
    border: 0;
}

.dk-drawer.summary {
    top: auto;
    width: min(380px, calc(100% - 24px));
}

.dk-visit-summary {
    display: grid;
    gap: 4px;
    padding: 14px 16px;
}

.dk-visit-summary strong {
    font-family: var(--font-display);
    font-size: 1.15rem;
}

.dk-visit-summary span,
.dk-visit-summary small {
    color: var(--muted);
}

@keyframes dk3-drawer {
    from { opacity: 0; transform: translateX(16px); }
    to { opacity: 1; transform: none; }
}

/* Deckhands */
.dk-crew {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 14px;
    margin: 0 0 12px;
    color: var(--muted);
}

.dk-crew:empty {
    display: none;
}

.dk-crew b {
    color: var(--text);
}

.dk-crew-hands {
    display: inline-flex;
    gap: 5px;
}

.dk-crew-hands i {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #4ade80;
    box-shadow: 0 0 0 2px rgba(74, 222, 128, 0.25);
}

.dk-crew-hands i.busy {
    background: #f59e0b;
    box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.25);
}

.dk-crew button {
    margin-left: auto;
}

.dk-ready,
.dk-hammer {
    display: grid;
    place-items: center;
    min-width: 22px;
    height: 22px;
    padding: 0 6px;
    border-radius: var(--ff-r-pill, 999px);
    font-style: normal;
    font-size: 0.75rem;
    font-weight: 900;
}

.dk-ready {
    background: #4ade80;
    color: #052e16;
    animation: dk-pulse 1.6s ease-in-out infinite;
}

.dk-hammer {
    background: rgba(245, 158, 11, 0.2);
    border: 1px solid rgba(245, 158, 11, 0.6);
}

.dk-hammer::before {
    content: "";
    width: 12px;
    height: 12px;
    background: #f59e0b;
    -webkit-mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'><path d='M14 6l4 4M4 20l9-9M12 4l8 8-3 3-8-8z'/></svg>") center / contain no-repeat;
    mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'><path d='M14 6l4 4M4 20l9-9M12 4l8 8-3 3-8-8z'/></svg>") center / contain no-repeat;
}

@keyframes dk-pulse {
    50% { box-shadow: 0 0 0 5px rgba(74, 222, 128, 0.18); }
}

.dk-art.ghost {
    opacity: 0.35;
    filter: grayscale(1);
}

/* Detail */
.dk-detail {
    display: grid;
    gap: 12px;
    min-width: 0;
    padding: 14px;
    border: 1px solid color-mix(in srgb, var(--bc) 40%, var(--line));
    border-radius: var(--ff-r-lg, 18px);
    background:
        radial-gradient(420px 180px at 0% 0%, color-mix(in srgb, var(--bc) 14%, transparent), transparent 70%),
        var(--hb-card, rgba(14, 34, 50, 0.92));
}

.dk-detail-head {
    display: grid;
    grid-template-columns: 116px minmax(0, 1fr);
    gap: 14px;
    align-items: center;
}

.dk-detail-art {
    padding: 6px;
    border-radius: var(--ff-r-lg, 14px);
    background: linear-gradient(180deg, #a4d4f2, #d8eefb 70%);
}

.dk-detail-art .dk-art {
    display: block;
    width: 100%;
}

.dk-detail h3 {
    display: flex;
    align-items: baseline;
    gap: 10px;
    margin: 0 0 4px;
    font-family: var(--font-display);
    font-size: 1.35rem;
}

.dk-level {
    color: var(--bc);
    font-size: 0.95rem;
    font-weight: 900;
}

.dk-level small {
    color: var(--muted);
}

.dk-detail p {
    margin: 0;
    color: var(--muted);
}

.dk-pips {
    display: flex;
    gap: 4px;
    margin-top: 8px;
}

.dk-pips i {
    flex: 1;
    max-width: 26px;
    height: 6px;
    border-radius: 3px;
    background: rgba(255, 255, 255, 0.1);
}

.dk-pips i.on {
    background: var(--bc);
}

.dk-effects {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 8px;
}

.dk-effects span {
    display: grid;
    gap: 2px;
    padding: 8px 10px;
    border-radius: var(--ff-r-lg, 12px);
    background: rgba(255, 255, 255, 0.04);
}

.dk-effects em {
    color: var(--muted);
    font-size: 0.72rem;
    font-style: normal;
    font-weight: 900;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.dk-effects .next em {
    color: #4ade80;
}

.dk-upgrade {
    display: grid;
    gap: 8px;
    padding: 12px;
    border: 1px dashed color-mix(in srgb, var(--bc) 45%, var(--line));
    border-radius: var(--ff-r-lg, 14px);
}

.dk-upgrade.maxed {
    border-style: solid;
    border-color: rgba(250, 204, 21, 0.6);
    color: #facc15;
}

.dk-upgrade-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 10px;
}

.dk-costs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.dk-costs span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: var(--ff-r-md, 10px);
    background: rgba(255, 255, 255, 0.06);
    font-weight: 800;
}

.dk-costs span.short {
    background: rgba(248, 113, 113, 0.14);
    color: #fca5a5;
}

.dk-costs small {
    color: var(--muted);
    font-weight: 700;
}

.dk-fish-chip {
    width: 12px;
    height: 12px;
    border-radius: 3px;
    background: currentColor;
}

.dk-build {
    justify-self: start;
    min-width: 140px;
}

.dk-problem {
    color: #fca5a5;
}

.dk-muted {
    color: var(--muted);
}

.dk-bar {
    height: 8px;
    overflow: hidden;
    border-radius: var(--ff-r-pill, 999px);
    background: rgba(255, 255, 255, 0.08);
}

.dk-bar i {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--bc, #38bdf8), #fef3c7);
    transition: width 0.9s linear;
}

.dk-timer {
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.dk-use {
    display: grid;
    gap: 10px;
    padding-top: 4px;
    border-top: 1px solid var(--line);
}

.dk-use h4,
.dk-visit h4 {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 4px 10px;
    margin: 4px 0 0;
    font-family: var(--font-display);
    font-size: 1.05rem;
}

.dk-use h4 small,
.dk-visit h4 small {
    color: var(--muted);
    font-family: inherit;
    font-size: 0.8rem;
    font-weight: 700;
}

.dk-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.dk-form {
    display: flex;
    flex-wrap: wrap;
    align-items: end;
    gap: 8px 12px;
}

.dk-form label {
    display: grid;
    gap: 3px;
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 800;
}

.dk-form select {
    min-width: 160px;
}

.dk-jobs,
.dk-trophies,
.dk-wares {
    display: grid;
    gap: 6px;
}

.dk-job,
.dk-trophy,
.dk-ware {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(80px, 160px) auto;
    align-items: center;
    gap: 10px;
    padding: 6px 10px;
    border-radius: var(--ff-r-lg, 12px);
    background: rgba(255, 255, 255, 0.04);
}

.dk-job:has(> .dk-fish) {
    grid-template-columns: minmax(0, 1fr) auto auto;
}

.dk-job > span,
.dk-ware > span {
    display: grid;
    min-width: 0;
}

.dk-job small,
.dk-ware small {
    color: var(--muted);
}

.dk-trophy {
    grid-template-columns: minmax(0, 1fr) auto;
}

.dk-ware {
    grid-template-columns: minmax(0, 1fr) auto;
}

.dk-ware.sold {
    opacity: 0.55;
}

.dk-fish {
    display: grid;
    grid-template-columns: 40px minmax(0, 1fr) auto;
    align-items: center;
    gap: 8px;
    min-width: 0;
}

.dk-fish .fish-icon {
    width: 40px;
    height: 40px;
}

.dk-fish-name {
    display: grid;
    min-width: 0;
}

/* Mutation tags under a trophy or a fish in the chooser. */
.dk-fish-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 3px;
    margin-top: 2px;
    font-size: 0.82rem;
}

.dk-fish-tags .ff-mutation-tag {
    font-size: 0.62rem;
}

.dk-fish strong {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dk-price {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-weight: 900;
    white-space: nowrap;
}

.dk-mini {
    min-height: 0;
    padding: 4px 10px;
    font-size: 0.78rem;
}

.dk-stock {
    display: grid;
    gap: 4px;
    font-weight: 800;
}

.dk-stats {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    gap: 8px;
}

.dk-stats span {
    display: grid;
    padding: 8px 10px;
    border-radius: var(--ff-r-lg, 12px);
    background: rgba(255, 255, 255, 0.04);
}

.dk-stats b {
    font-family: var(--font-display);
    font-size: 1.25rem;
}

.dk-stats small {
    color: var(--muted);
}

.dk-ice {
    display: flex;
    align-items: center;
    gap: 8px;
}

.dk-ice i {
    width: 22px;
    height: 22px;
    border-radius: var(--ff-r-md, 6px);
    background: rgba(255, 255, 255, 0.08);
    transform: rotate(45deg);
}

.dk-ice i.on {
    background: linear-gradient(135deg, #f0f9ff, #7dd3fc);
    box-shadow: 0 0 10px rgba(125, 211, 252, 0.55);
}

/* Critter log */
.dk-critters {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(104px, 1fr));
    gap: 8px;
}

.dk-critter {
    display: grid;
    justify-items: center;
    gap: 2px;
    padding: 8px 6px;
    border: 1px solid var(--line);
    border-radius: var(--ff-r-lg, 12px);
    background: rgba(255, 255, 255, 0.04);
    text-align: center;
}

.dk-critter.rare {
    border-color: rgba(250, 204, 21, 0.45);
}

.dk-critter.unknown .dk-critter-art {
    filter: brightness(0) opacity(0.35);
}

.dk-critter strong {
    font-size: 0.82rem;
}

.dk-critter small {
    color: var(--muted);
    font-size: 0.72rem;
}

.dk-critter-art {
    width: 64px;
    height: 48px;
}

/* Locked and visits */
.dk-locked {
    display: grid;
    gap: 10px;
    justify-items: center;
    padding: 22px;
    border: 1px dashed var(--line);
    border-radius: var(--ff-r-lg, 18px);
    color: var(--muted);
    text-align: center;
    grid-column: 1 / -1;
}

.dk-locked strong {
    color: var(--text);
    font-family: var(--font-display);
    font-size: 1.25rem;
}

.dk-unlock-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 8px;
    width: 100%;
    max-width: 760px;
}

.dk-unlock-grid div {
    display: grid;
    gap: 4px;
    padding: 8px 10px;
    border-radius: var(--ff-r-lg, 12px);
    background: rgba(255, 255, 255, 0.04);
    text-align: left;
}

.dk-unlock-grid div.done b {
    color: #4ade80;
}

.dk-visit {
    display: grid;
    gap: 14px;
    grid-column: 1 / -1;
}

.dk-visit-buildings {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
    gap: 8px;
}

.dk-visit-buildings div {
    display: grid;
    justify-items: center;
    gap: 2px;
    padding: 6px;
    border: 1px solid color-mix(in srgb, var(--bc) 35%, var(--line));
    border-radius: var(--ff-r-lg, 12px);
    text-align: center;
}

.dk-visit-buildings .dk-art {
    width: 72px;
    height: 60px;
}

.dk-visit-buildings small {
    color: var(--muted);
}

.dk-visit .dk-trophies {
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
}

/* Keep Net picker */
.dk-picker {
    position: absolute;
    inset: 12px;
    z-index: 5;
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    gap: 10px;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: var(--ff-r-lg, 18px);
    background: rgba(8, 22, 34, 0.97);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.55);
}

.dk-picker[hidden] {
    display: none;
}

.dk-picker header {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.dk-picker header strong {
    font-family: var(--font-display);
    font-size: 1.15rem;
}

.dk-picker input[type="search"] {
    flex: 1 1 200px;
}

.dk-picker-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    align-content: start;
    gap: 6px;
    overflow-y: auto;
}

.dk-picker-list button {
    min-height: 0;
    padding: 6px 10px;
    border: 1px solid var(--line);
    border-radius: var(--ff-r-lg, 12px);
    background: rgba(255, 255, 255, 0.04);
    color: var(--text);
    text-align: left;
}

.dk-picker-list button:hover {
    border-color: #facc15;
}

.dk-modal {
    position: relative;
}

/* Pond HUD chips */
.dk-hud {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.dk-hud[hidden] {
    display: none;
}

.dk-hud-chip {
    padding: 3px 9px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: var(--ff-r-pill, 999px);
    background: rgba(8, 22, 34, 0.78);
    color: #e2e8f0;
    font-size: 0.74rem;
    font-weight: 900;
    font-variant-numeric: tabular-nums;
}

.dk-hud-chip.horn {
    border-color: rgba(251, 146, 60, 0.7);
    color: #fdba74;
}

.dk-hud-chip.boss {
    border-color: rgba(248, 113, 113, 0.6);
    color: #fca5a5;
}

.dk-hud-chip.beacon {
    border-color: rgba(253, 230, 138, 0.7);
    color: #fde68a;
}

@media (max-width: 760px) {
    .dk-stage-wrap {
        height: clamp(400px, 66vh, 680px);
    }

    .dk-drawer {
        top: auto;
        right: 8px;
        bottom: 8px;
        left: 8px;
        width: auto;
        max-height: 64%;
    }

    .dk3-hint {
        display: none;
    }
}

@media (max-width: 560px) {
    .dk-detail-head {
        grid-template-columns: 76px minmax(0, 1fr);
    }

    .dk-job {
        grid-template-columns: minmax(0, 1fr) auto;
    }

    .dk-job .dk-bar {
        grid-column: 1 / -1;
        order: 3;
    }

    .dk-wallet {
        order: 3;
    }
}

html:is(.ff-low-detail, .ff-motion-off) .dk3-bob,
html:is(.ff-low-detail, .ff-motion-off) .dk3-sail,
html:is(.ff-low-detail, .ff-motion-off) .dk3-ripples,
html:is(.ff-low-detail, .ff-motion-off) .dk3-foam,
html:is(.ff-low-detail, .ff-motion-off) .dk3-beam,
html:is(.ff-low-detail, .ff-motion-off) .dk3-glow,
html:is(.ff-low-detail, .ff-motion-off) .dk3-wave,
html:is(.ff-low-detail, .ff-motion-off) .dk3-ring,
html:is(.ff-low-detail, .ff-motion-off) .dk3-bubble,
html:is(.ff-low-detail, .ff-motion-off) .dk-drawer,
html:is(.ff-low-detail, .ff-motion-off) .dk-ready {
    animation: none !important;
}

/* Keep Net choosers: one roomy row per fish. */
.dk-picker-list {
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    grid-auto-rows: max-content;
    gap: 10px;
}

.dk-picker-list button {
    min-height: max-content;
    padding: 10px 12px;
}

.dk-pick-row {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
}

.dk-pick-row.has-lead {
    grid-template-columns: 52px minmax(0, 1fr) auto auto;
}

/* Picker summary, rarity chips, toggle and sort */
.dk-picker {
    z-index: 30;
    grid-template-rows: auto auto auto minmax(0, 1fr) auto;
    background: #081620;
}

.dk-picker-summary {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 16px;
    color: var(--muted);
    font-size: 0.82rem;
}

.dk-picker-summary b {
    color: var(--text);
}

.dk-picker-summary:empty,
.dk-picker-more:empty {
    display: none;
}

.dk-picker-tools {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 14px;
}

.dk-picker-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}

.dk-picker-chips button {
    min-height: 0;
    padding: 4px 10px;
    border: 1px solid var(--line);
    border-radius: var(--ff-r-pill, 999px);
    background: rgba(255, 255, 255, 0.04);
    font-size: 0.78rem;
    font-weight: 800;
}

.dk-picker-chips button small {
    color: var(--muted);
    font-weight: 700;
}

.dk-picker-chips button.on {
    border-color: #facc15;
    background: rgba(250, 204, 21, 0.16);
}

.dk-picker-toggle,
.dk-picker-sort {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.82rem;
    font-weight: 700;
    margin: 0;
}

.dk-picker-toggle input {
    width: 16px;
    height: 16px;
    min-height: 0;
    margin: 0;
    padding: 0;
    accent-color: #facc15;
}

.dk-picker-sort select {
    width: auto;
}

.dk-picker-sort {
    margin-left: auto;
}

.dk-picker-more {
    margin: 0;
    color: var(--muted);
    font-size: 0.8rem;
    text-align: center;
}

.dk-mount-gain {
    display: grid;
    justify-items: end;
    color: #4ade80;
    font-size: 0.95rem;
    font-weight: 900;
    line-height: 1.1;
}

.dk-mount-gain small {
    color: var(--muted);
    font-size: 0.66rem;
    font-weight: 700;
}

.dk-mount-gain.capped {
    color: #fbbf24;
}

.dk-picker-mount .dk-price {
    opacity: 0.7;
    font-size: 0.8rem;
}

.dk-picker-list button.dk-mount-pick.best {
    border-color: rgba(74, 222, 128, 0.6);
    background: rgba(74, 222, 128, 0.07);
}

@media (max-width: 520px) {
    .dk-pick-row.has-lead {
        grid-template-columns: 44px minmax(0, 1fr) auto;
    }

    .dk-pick-row.has-lead .dk-price {
        display: none;
    }

    .dk-picker-sort {
        margin-left: 0;
    }
}

.dk-pick-row .fish-icon {
    width: 52px;
    height: 52px;
}

.dk-pick-name {
    display: grid;
    gap: 3px;
    min-width: 0;
}

.dk-pick-name strong {
    font-size: 0.98rem;
    line-height: 1.2;
    overflow-wrap: anywhere;
}

.dk-pick-name small {
    color: var(--muted);
    font-size: 0.78rem;
    line-height: 1.35;
}

.dk-pick-name small b {
    font-weight: 900;
}

.dk-pick-row .dk-price {
    font-size: 0.95rem;
}

.dk-trophy,
.dk-job:has(> .dk-fish) {
    padding: 9px 12px;
}

/* The Ice House prompt over the pond. */
.dk-ice-prompt {
    position: absolute;
    top: 50%;
    left: 50%;
    z-index: 30;
    display: grid;
    gap: 8px;
    width: min(380px, calc(100% - 32px));
    padding: 14px 16px;
    border: 1px solid rgba(165, 243, 252, 0.6);
    border-radius: var(--ff-r-lg, 16px);
    background: rgba(8, 30, 44, 0.95);
    box-shadow: 0 0 30px rgba(125, 211, 252, 0.35), 0 16px 40px rgba(0, 0, 0, 0.5);
    color: #e0f2fe;
    transform: translate(-50%, -50%);
    animation: dk-ice-in 0.2s ease-out;
}

.dk-ice-prompt strong {
    font-family: var(--font-display);
    font-size: 1.15rem;
}

.dk-ice-prompt span {
    color: #bae6fd;
}

.dk-ice-prompt-bar {
    height: 6px;
    overflow: hidden;
    border-radius: var(--ff-r-pill, 999px);
    background: rgba(255, 255, 255, 0.12);
}

.dk-ice-prompt-bar i {
    display: block;
    height: 100%;
    background: linear-gradient(90deg, #7dd3fc, #f0f9ff);
    animation: dk-ice-drain linear forwards;
}

.dk-ice-prompt-actions {
    display: flex;
    gap: 8px;
}

.dk-ice-prompt-actions button:first-child {
    flex: 1;
    border-color: #7dd3fc;
    background: rgba(125, 211, 252, 0.18);
    color: #f0f9ff;
}

@keyframes dk-ice-in {
    from { opacity: 0; transform: translate(-50%, -45%); }
}

@keyframes dk-ice-drain {
    from { width: 100%; }
    to { width: 0; }
}



/* A building that can be upgraded now: a gold arrow, bobbing. */
.dk3-bubble.upgrade {
    animation: dk3-hop 1.4s ease-in-out infinite;
}

.dk3-bubble.upgrade circle {
    fill: #facc15;
    stroke: #422006;
    stroke-width: 2;
}



/*==================================================
    The Lodge isle
    Smoke, turning cogs and sails, and sparkles on
    the Lodge buildings; the Lodge crew and the panel
    art for a Lodge building.
==================================================*/

.dk3-smoke,
.dk3-spin,
.dk3-twinkle {
    animation-delay: calc(var(--d, 0s) - var(--dk3-t, 0s)) !important;
}

.dk3-smoke {
    animation: dk3-smoke 3.6s ease-in-out infinite;
}

.dk3-spin {
    transform-box: fill-box;
    transform-origin: center;
    animation: dk3-spin 7s linear infinite;
}

.dk3-spin.slow {
    animation-duration: 11s;
}

.dk3-twinkle {
    transform-box: fill-box;
    transform-origin: center;
    animation: dk3-twinkle 2.6s ease-in-out infinite;
}

@keyframes dk3-smoke {
    0% { opacity: 0.25; transform: translate(0, 4px); }
    50% { opacity: 1; }
    100% { opacity: 0; transform: translate(6px, -14px); }
}

@keyframes dk3-spin {
    to { transform: rotate(360deg); }
}

@keyframes dk3-twinkle {
    0%, 100% { opacity: 0.2; transform: scale(0.6); }
    50% { opacity: 1; transform: scale(1.1); }
}

html:is(.ff-low-detail, .ff-motion-off) .dk3-smoke,
html:is(.ff-low-detail, .ff-motion-off) .dk3-spin,
html:is(.ff-low-detail, .ff-motion-off) .dk3-twinkle {
    animation: none !important;
}

.dk-lodge-art svg {
    display: block;
    width: 100%;
    height: auto;
}

.dk-lodge-tag {
    display: inline-block;
    margin-top: 6px;
    padding: 2px 9px;
    border: 1px solid color-mix(in srgb, var(--bc) 50%, transparent);
    border-radius: var(--ff-r-pill, 999px);
    background: color-mix(in srgb, var(--bc) 14%, transparent);
    color: var(--text);
    font-size: 0.72rem;
    font-weight: 800;
}

.dk-crew-lodge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 3px 10px;
    border: 1px solid rgba(251, 191, 36, 0.35);
    border-radius: var(--ff-r-pill, 999px);
    background: rgba(251, 191, 36, 0.08);
}

.dk-crew-lodge i {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #4ade80;
    box-shadow: 0 0 0 2px rgba(74, 222, 128, 0.25);
}

.dk-crew-lodge.busy i {
    background: #f59e0b;
    box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.25);
}

.dk-crew-lodge .dk-timer {
    color: #fde68a;
}

.dk-refund {
    display: flex;
    flex: 1 1 100%;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    border: 1px solid rgba(132, 204, 22, 0.45);
    border-radius: var(--ff-r-lg, 12px);
    background: rgba(132, 204, 22, 0.1);
    color: var(--text);
}

.dk-refund span {
    flex: 1;
    min-width: 0;
}

.dk-refund .dk-coin,
.dk-refund .hb-pearl-icon {
    margin: 0 3px;
    vertical-align: -2px;
}

.dk-crew .dk-refund button {
    margin-left: 0;
    flex: none;
    padding: 2px 9px;
    font-size: 1.1rem;
    line-height: 1;
}

.dk-drawer.locked .dk-drawer-close {
    float: right;
}
