/* ============================================================
   ekphrasis.css — Magazine layout poetry feed
   Left 70% main + right 30% sidebar
   ============================================================ */

/* ── Magazine outer wrapper ── */
.ekphrasis-magazine {
    display: grid;
    grid-template-columns: 70% 30%;
    max-width: 1400px;
    margin: 0 auto;
    min-height: 80vh;
}

/* ── Left main column ── */
.ekphrasis-main {
    padding-bottom: 60px;
}

/* ── Ekphrasis title — top of main column ── */
.ekphrasis-title {
    padding: 2rem 3rem 2.0rem;
    display: flex;
    align-items: baseline;
    gap: 0.75rem;
}

.ekphrasis-title-heading {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 3em;
    font-style: italic;
    font-weight: 500;
    color: #111;
    line-height: 1;
}

.ekphrasis-title-greek {
    font-size: 0.72em;
    color: #ccc;
    font-style: italic;
    font-family: var(--font-sans);
}

/* ── Featured poem ── */
.ekphrasis-featured {
    display: grid;
    grid-template-columns: 1fr 1fr;
    cursor: pointer;
    transition: background 0.15s;
    margin-bottom: 0.2rem;
}
.ekphrasis-featured:hover { background: #fafafa; }

/* Featured image column */
.ekphrasis-featured-img-col {
    overflow: hidden;
}
/* Featured image — smaller, contained */
.ekphrasis-featured-img {
    width: 100%;
    height: auto;
    object-fit: contain;
    display: block;
    transition: opacity 0.2s;
}
.ekphrasis-featured:hover .ekphrasis-featured-img { opacity: 0.92; }
.ekphrasis-featured-img--empty {
    width: 100%;
    min-height: 220px;
    background: var(--teal-light);
}

/* Featured poem column */
.ekphrasis-featured-poem-col {
    padding: 2.5rem 3rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Theme tag — concept label, shown when set */
.ekphrasis-featured-theme {
    font-size: 0.68em;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--teal);
    font-family: var(--font-sans);
    margin-bottom: 0.75rem;
}

.ekphrasis-featured-poem-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.8em;
    font-weight: 700;
    color: #111;
    line-height: 1.2;
    margin-bottom: 1rem;
}

/* Poem text — clamp to 8 lines */
.ekphrasis-featured-poem-text {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1em;
    color: #444;
    line-height: 2.1;
    white-space: pre-wrap;
    word-break: break-word;
    display: -webkit-box;
    -webkit-line-clamp: 8;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 1.5rem;
    flex: 1;
}

.ekphrasis-featured-byline {
    font-size: 0.8em;
    color: #aaa;
    font-family: var(--font-sans);
    letter-spacing: 0.3px;
}

/* ── Feed cards ── */
.ekphrasis-feed {
    columns: 3;
    column-gap: 16px;
    padding: 2rem 0
}

/* Card — image top, text below */
.ekphrasis-card {
    break-inside: avoid;
    display: flex;
    flex-direction: column;
    cursor: pointer;
    transition: background 0.15s;
    margin-bottom: 24px;
}
/* Poem column — image top, text below */
.ekphrasis-card-poem {
    padding: 0.75rem 0.5rem 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    min-width: 0;
}

.ekphrasis-card:hover { background: #fafafa; }
.ekphrasis-card-img-wrap {
    display: flex;
    flex-direction: column;
    background: #fafafa;
}

.ekphrasis-card-img {
    width: 100%;
    height: auto;
    display: block;
    transition: opacity 0.2s;
    min-height: 80px;
    background: #f5f5f5;
}
.ekphrasis-card:hover { background: #fafafa; }

/* No image — poem full width */
.ekphrasis-card--no-image {
    grid-template-columns: 1fr;
}

/* Odd card: image left, poem right — border flips */
.ekphrasis-card--odd .ekphrasis-card-poem,
.ekphrasis-card:has(.ekphrasis-card-img-wrap:first-child) .ekphrasis-card-poem {
}

.ekphrasis-card--no-image .ekphrasis-card-poem {
    border-right: none;
    border-left: none;
    max-width: 720px;
}

/* Theme tag on card */
.ekphrasis-card-theme {
    font-size: 0.65em;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--teal);
    font-family: var(--font-sans);
    margin-bottom: 0.4rem;
}

/* ekphra pick badge */
.ekphrasis-card-pick {
    font-size: 0.65em;
    color: var(--teal);
    font-family: var(--font-sans);
    letter-spacing: 0.1em;
    margin-bottom: 0.4rem;
}

/* Title — large, dominant */
.ekphrasis-card-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.2em;
    font-weight: 700;
    color: #111;
    line-height: 1.3;
    margin-bottom: 0.5rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Poem text — smaller, 3 lines */
.ekphrasis-card-text {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 0.82em;
    color: #555;
    line-height: 1.85;
    white-space: pre-wrap;
    word-break: break-word;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 0;
}

/* Byline — medium, spaced */
.ekphrasis-card-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 0.6rem;
    font-size: 0.78em;
    color: #888;
    font-family: var(--font-sans);
}

.ekphrasis-card-byline {
    display: flex;
    flex-direction: column;
    gap: 3px;
}
.ekphrasis-card-poet   { color: #888; }
.ekphrasis-card-artwork { color: #ccc; font-size: 0.88em; }

.ekphrasis-card-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

/* Image column */
.ekphrasis-card-img-wrap {
    overflow: hidden;
    display: flex;
    align-items: center;
    background: #fafafa;
}
.ekphrasis-card-img {
    width: 100%;
    height: auto;
    display: block;
    transition: opacity 0.2s;
}
.ekphrasis-card:hover .ekphrasis-card-img { opacity: 0.92; }

/* Actions row — below image or below poem if no image */
.ekphrasis-card-foot {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    padding: 6px 8px;
}

.ekphrasis-audio-btn {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 0.82em;
    color: #ccc;
    display: flex;
    align-items: center;
    gap: 3px;
    padding: 2px 4px;
    transition: color 0.15s;
}
.ekphrasis-audio-btn:hover  { color: var(--teal); }
.ekphrasis-audio-btn.playing { color: var(--teal); }

.ekphrasis-comment-btn {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 0.82em;
    color: #ccc;
    display: flex;
    align-items: center;
    gap: 3px;
    padding: 2px 4px;
    transition: color 0.15s;
    font-family: var(--font-sans);
}
.ekphrasis-comment-btn:hover { color: #888; }

/* Like / feature buttons */
.ekphrasis-like-btn {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 0.82em;
    color: #ccc;
    display: flex;
    align-items: center;
    gap: 3px;
    padding: 2px 4px;
    transition: color 0.15s;
    font-family: var(--font-sans);
}
.ekphrasis-like-btn:hover { color: #e07b8a; }
.ekphrasis-like-btn.liked { color: #e07b8a; }

.ekphrasis-feature-btn {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 0.75em;
    color: #ddd;
    padding: 2px 4px;
    transition: color 0.15s;
}
.ekphrasis-feature-btn:hover { color: var(--teal); }
.ekphrasis-feature-btn.on    { color: var(--teal); }

/* ── Right sidebar — latest poems list ── */
.ekphrasis-sidebar {
    padding: 0 0 0 2rem;
    position: sticky;
    top: 0;
    align-self: start;
    max-height: calc(100vh - 120px);
    overflow-y: auto;
}

.ekphrasis-sidebar-label {
    font-size: 0.62em;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: #bbb;
    font-family: var(--font-sans);
    padding: 1.5rem 2rem 1rem;
}

/* Theme tag on sidebar */
.ekphrasis-sidebar-theme {
    font-size: 0.6em;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--teal);
    font-family: var(--font-sans);
    margin-bottom: 0.3rem;
}

/* Sidebar poem title — big and bold */
.ekphrasis-sidebar-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.15em;
    font-weight: 700;
    color: #111;
    line-height: 1.3;
    margin-bottom: 0.4rem;
}

.ekphrasis-sidebar-byline {
    font-size: 0.72em;
    color: #aaa;
    font-family: var(--font-sans);
    letter-spacing: 0.3px;
}

/* Sidebar group label */
.ekphrasis-sidebar-group-label {
    font-size: 0.82em;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--teal);
    font-family: var(--font-sans);
    padding: 2rem 1.5rem 0.4rem;
    font-weight: 600;
}

.ekphrasis-sidebar-group {
    border-bottom: 1px solid var(--border);
    padding-bottom: 0.5rem;
    margin-bottom: 0.5rem;
}

/* Sidebar item — thumbnail + text side by side */
.ekphrasis-sidebar-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem 1.5rem;
   
    text-decoration: none;
    transition: background 0.15s;
}
.ekphrasis-sidebar-item:hover { background: #fafafa; }

.ekphrasis-sidebar-thumb {
    width: 100px;
    height: auto;
    display: block;
    flex-shrink: 0;
}

.ekphrasis-sidebar-text {
    flex: 1;
    min-width: 0;
}

/* ── Empty / Loading ── */
.ekphrasis-empty {
    text-align: center;
    padding: 4rem 2rem;
    color: #ccc;
    font-size: 1em;
    line-height: 2;
    font-family: 'Playfair Display', Georgia, serif;
    font-style: italic;
}
.ekphrasis-loading {
    text-align: center;
    padding: 2rem;
    font-size: 0.82em;
    color: #ccc;
    letter-spacing: 1px;
}

/* ── Pagination ── */
.ekphrasis-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 2rem 0 4rem;
}
.ekphrasis-page-btn {
    background: transparent;
    border: none;
    padding: 4px 0;
    cursor: pointer;
    font-size: 0.78em;
    color: #ccc;
    font-family: var(--font-sans);
    transition: color 0.15s;
    min-width: 16px;
    position: relative;
}
.ekphrasis-page-btn:hover { color: var(--gray-mid); }
.ekphrasis-page-btn.active { color: var(--gray-dark); }
.ekphrasis-page-btn.active::after {
    content: '';
    display: block;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--teal);
    margin: 3px auto 0;
}

/* ── Toolbar controls (in $pageHeroRight) ── */
.ekphrasis-search {
    background: transparent;
    border: none;
    border-bottom: 1px solid var(--border);
    padding: 3px 6px;
    font-family: var(--font-sans);
    font-size: 0.74em;
    color: #666;
    outline: none;
    width: 160px;
    transition: border-color 0.15s;
}
.ekphrasis-search::placeholder { color: #ccc; }
.ekphrasis-search:focus { border-bottom-color: var(--teal); }

.ekphrasis-chip {
    background: transparent;
    border: none;
    padding: 4px 0;
    font-size: 0.74em;
    color: #bbb;
    font-family: var(--font-sans);
    letter-spacing: 0.3px;
    cursor: pointer;
    transition: color 0.15s;
    position: relative;
}
.ekphrasis-chip:hover { color: #666; }
.ekphrasis-chip.active { color: #111; }
.ekphrasis-chip.active::after {
    content: '';
    display: block;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--teal);
    margin: 3px auto 0;
}

.ekphrasis-spacer { flex: 1; }

.ekphrasis-count {
    font-size: 0.72em;
    color: #ccc;
    letter-spacing: 0.5px;
}

/* Rating filter menu */
.ekphrasis-filter-wrap { position: relative; }

.ekphrasis-filter-btn {
    background: none;
    border: none;
    cursor: pointer;
    color: #aaa;
    font-size: 1rem;
    letter-spacing: 0.08em;
    padding: 5px 8px;
    border-radius: 4px;
    transition: color 0.15s;
}
.ekphrasis-filter-btn:hover { color: var(--gray-mid); }
.ekphrasis-filter-btn.active { color: var(--teal-dark); }

.ekphrasis-filter-menu {
    display: none;
    position: absolute;
    right: 0;
    top: calc(100% + 4px);
    background: white;
    border: 1px solid var(--border);
    border-radius: 6px;
    box-shadow: var(--shadow);
    z-index: 100;
    min-width: 160px;
    overflow: hidden;
}
.ekphrasis-filter-menu.open { display: block; }

.ekphrasis-filter-menu-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    font-size: 0.82em;
    color: var(--gray-dark);
    cursor: pointer;
    transition: background 0.12s;
    border: none;
    background: none;
    width: 100%;
    text-align: left;
    font-family: var(--font-sans);
}
.ekphrasis-filter-menu-item:hover { background: var(--gray-light); }
.ekphrasis-filter-menu-item.active {
    color: var(--teal-dark);
    background: var(--teal-light);
}

.ekphrasis-filter-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}
.ekphrasis-filter-dot.general   { background: var(--teal); }
.ekphrasis-filter-dot.mature    { background: #e67e22; }
.ekphrasis-filter-dot.sensitive { background: #c0392b; }

/* ── Write modal header ── */
.ekphrasis-write-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 6px 22px 12px;
    border-bottom: 1px solid #f0f0f0;
    flex-shrink: 0;
}
.ekphrasis-write-header-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.1em;
    font-style: italic;
    color: #111;
}
.ekphrasis-write-header-title span { color: var(--teal); }
.ekphrasis-write-close {
    background: none; border: none;
    font-size: 1.4em; color: #aaa; cursor: pointer;
}
.ekphrasis-write-close:hover { color: #333; }
.ekphrasis-write-error {
    margin: 0 22px 8px;
    padding: 8px 12px;
    background: #fff5f5;
    border: 1px solid #fcc;
    border-radius: 6px;
    color: #c0392b;
    font-size: 0.82em;
    flex-shrink: 0;
}
.ekphrasis-write-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    overflow-y: auto;
    flex: 1;
    min-height: 0;
}
.ekphrasis-write-col { padding: 16px 22px; }
.ekphrasis-write-col--left { border-right: 1px solid #f0f0f0; }
.ekphrasis-write-col--right { display: flex; flex-direction: column; }
.ekphrasis-write-label {
    display: block;
    font-size: 0.72em;
    font-weight: 600;
    color: #666;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    margin-bottom: 5px;
}
.ekphrasis-artwork-select {
    border: 1px solid #e0e0e0;
    border-radius: 7px;
    overflow: hidden;
    margin-bottom: 14px;
}
.ekphrasis-artwork-search {
    width: 100%;
    box-sizing: border-box;
    border: none;
    border-bottom: 1px solid #f0f0f0;
    padding: 8px 12px;
    font-size: 0.82em;
    font-family: var(--font-sans);
    outline: none;
    background: #fafafa;
}
.ekphrasis-artwork-search:focus { background: #fff; }
.ekphrasis-artwork-list { max-height: 200px; overflow-y: auto; }
.ekphrasis-artwork-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    cursor: pointer;
    border-bottom: 1px solid #f5f5f5;
    transition: background 0.1s;
}
.ekphrasis-artwork-item:hover,
.ekphrasis-artwork-item.selected { background: var(--teal-light); }
.ekphrasis-artwork-item:last-child { border-bottom: none; }
.ekphrasis-artwork-thumb {
    width: 36px; height: 36px;
    object-fit: cover;
    border-radius: 4px;
    background: #eee;
    flex-shrink: 0;
}
.ekphrasis-artwork-name  { font-size: 0.8em; color: #333; line-height: 1.3; }
.ekphrasis-artwork-artist { font-size: 0.7em; color: #aaa; }
.ekphrasis-lang-select {
    width: 100%;
    box-sizing: border-box;
    border: 1px solid #e0e0e0;
    border-radius: 7px;
    padding: 7px 10px;
    font-size: 0.82em;
    font-family: var(--font-sans);
    color: #333;
    background: #fafafa;
    outline: none;
    margin-bottom: 14px;
}
.ekphrasis-lang-select:focus {
    border-color: var(--teal);
    background: #fff;
}
.ekphrasis-poem-input {
    width: 100%;
    box-sizing: border-box;
    border: none;
    outline: none;
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 0.95em;
    line-height: 1.9;
    color: #222;
    background: transparent;
    resize: none;
    min-height: 180px;
    flex: 1;
}
.ekphrasis-poem-input::placeholder { color: #ccc; font-style: italic; }
.ekphrasis-write-footer {
    padding: 12px 22px 20px;
    border-top: 1px solid #f0f0f0;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}
.ekphrasis-write-hint { font-size: 0.72em; color: #bbb; line-height: 1.5; flex: 1; }
.ekphrasis-write-submit {
    background: var(--teal);
    color: #fff;
    border: none;
    padding: 10px 24px;
    border-radius: 7px;
    font-family: 'Playfair Display', Georgia, serif;
    font-style: italic;
    font-size: 0.9em;
    cursor: pointer;
    transition: background 0.15s;
    white-space: nowrap;
    flex-shrink: 0;
}
.ekphrasis-write-submit:hover  { background: var(--teal-dark); }
.ekphrasis-write-submit:active { transform: scale(0.98); }
.ekphrasis-write-submit:disabled { opacity: 0.6; cursor: not-allowed; }

/* ── Fixed Write button ── */
.ekphrasis-launch-btn {
    position: fixed;
    bottom: 40px;
    right: 40px;
    z-index: 150;
    padding: 12px 24px;
    background: #333;
    color: #fff;
    border: none;
    border-radius: 4px;
    font-family: 'Playfair Display', Georgia, serif;
    font-style: italic;
    cursor: pointer;
    transition: background 0.2s, transform 0.2s;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
    pointer-events: auto;
}
.ekphrasis-launch-btn:hover {
    background: var(--teal);
    transform: translateY(-2px);
}

/* ── Lightbox ── */
.ekphrasis-lightbox {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(255,255,255,0.97);
    z-index: 1100;
    align-items: center;
    justify-content: center;
    cursor: zoom-out;
}
.ekphrasis-lightbox.open { display: flex; }
.ekphrasis-lightbox img {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
}
.ekphrasis-lightbox-close {
    position: absolute;
    top: 1.5rem; right: 1.5rem;
    color: rgba(0,0,0,0.35);
    font-size: 1.5em;
    background: none; border: none; cursor: pointer;
}
.ekphrasis-lightbox-caption {
    position: absolute;
    bottom: 2rem; left: 50%;
    transform: translateX(-50%);
    font-size: 0.78em;
    color: rgba(0,0,0,0.35);
    font-style: italic;
    white-space: nowrap;
}

/* ── Image type selector ── */
.ekphrasis-img-type-row {
    display: flex;
    gap: 6px;
    margin-bottom: 12px;
}

.ekphrasis-img-type-btn {
    background: none;
    border: 1px solid var(--border);
    padding: 4px 12px;
    font-size: 0.74em;
    font-family: var(--font-sans);
    color: #aaa;
    cursor: pointer;
    border-radius: 2px;
    transition: all 0.15s;
}
.ekphrasis-img-type-btn:hover  { color: #666; border-color: #bbb; }
.ekphrasis-img-type-btn.active { color: #111; border-color: #111; }

/* ── Related image upload area ── */
.ekphrasis-img-upload-area {
    border: 1px dashed var(--border);
    border-radius: 4px;
    overflow: hidden;
    cursor: pointer;
    transition: border-color 0.15s;
}
.ekphrasis-img-upload-area:hover { border-color: #bbb; }

.ekphrasis-img-upload-ui {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 24px;
    color: #ccc;
    font-size: 0.78em;
    font-family: var(--font-sans);
}

.ekphrasis-img-clear {
    display: block;
    width: 100%;
    background: none;
    border: none;
    border-top: 1px solid var(--border);
    padding: 6px;
    font-size: 0.72em;
    color: #aaa;
    cursor: pointer;
    font-family: var(--font-sans);
    transition: color 0.15s;
}
.ekphrasis-img-clear:hover { color: #e74c3c; }

/* ── Audio upload in write panel ── */
.ekphrasis-audio-upload {
    margin-bottom: 10px;
}

.ekphrasis-audio-upload-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 7px 12px;
    border: 1px dashed var(--border);
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.78em;
    color: #aaa;
    font-family: var(--font-sans);
    transition: all 0.15s;
}
.ekphrasis-audio-upload-btn:hover { border-color: #bbb; color: #666; }

.ekphrasis-audio-preview {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 7px 12px;
    border: 1px solid var(--border);
    border-radius: 4px;
    font-size: 0.78em;
    color: #666;
    font-family: var(--font-sans);
}

.ekphrasis-audio-preview button {
    background: none;
    border: none;
    color: #ccc;
    cursor: pointer;
    font-size: 1em;
    padding: 0;
    transition: color 0.15s;
}
.ekphrasis-audio-preview button:hover { color: #e74c3c; }
.ekphrasis-title-sub {
    padding: 0 3rem 1.5rem;
    font-size: 0.82em;
    color: #bbb;
    font-family: var(--font-sans);
    font-style: italic;
    letter-spacing: 0.3px;
}
/* ── Write panel backdrop ── */
.ekphrasis-write-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.45);
    z-index: 1100;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}
.ekphrasis-write-backdrop.open {
    display: block;
    opacity: 1;
    pointer-events: auto;
}

/* ── Write panel ── */
.ekphrasis-write-panel {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -48%) scale(0.97);
    z-index: 1101;
    background: #fff;
    border-radius: 4px;
    box-shadow: 0 12px 40px rgba(0,0,0,0.12);
    display: flex;
    flex-direction: column;
    width: min(92vw, 860px);
    max-height: 80vh;
    opacity: 0;
    transition: transform 0.28s cubic-bezier(0.32,0.72,0,1), opacity 0.28s ease;
    pointer-events: none;
}
.ekphrasis-write-panel.open {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
    pointer-events: auto;
}
.ekphrasis-write-handle {
    display: none;
}
.ekphrasis-write-handle-bar {
    width: 36px;
    height: 4px;
    background: #ddd;
    border-radius: 2px;
}

/* ── Selected artwork row ── */
.ekphrasis-selected-art-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    background: var(--teal-light);
    border-radius: 4px;
    border: 1px solid var(--teal-light);
}

.ekphrasis-selected-art-info {
    flex: 1;
    min-width: 0;
}
/* ── Mobile ── */
@media (max-width: 768px) {
    /* Stack columns on mobile */
    .ekphrasis-magazine {
        grid-template-columns: 1fr;
    }
    .ekphrasis-main {
        border-right: none;
    }
    .ekphrasis-sidebar {
        border-top: 2px solid var(--border);
        position: static;
    }
    .ekphrasis-title { padding: 1.5rem 1.5rem 1rem; }
    .ekphrasis-title-heading { font-size: 2.2em; }
    .ekphrasis-featured {
        grid-template-columns: 1fr;
    }
    .ekphrasis-featured-img-col { border-right: none; }
    .ekphrasis-featured-img { min-height: 200px; }
    .ekphrasis-featured-poem-col { padding: 1.5rem; }
    .ekphrasis-card {
        grid-template-columns: 1fr;
    }
    .ekphrasis-card-poem {
        border-right: none;
        border-left: none;
        padding: 1.5rem;
    }
    .ekphrasis-card-img-wrap { min-height: 200px; }
    .ekphrasis-write-body { grid-template-columns: 1fr; }
    .ekphrasis-write-col--left { border-right: none; border-bottom: 1px solid #f0f0f0; }
    .ekphrasis-search { width: 120px; }
    .ekphrasis-launch-btn { bottom: 20px; right: 20px; }
}