/* ======================================================================
   Casca do painel — estrutura do mockup 09 (mockups/painel.html), paleta do app
   Rail de 80 px à esquerda e corpo em papel, sem barra de topo.
   Os nomes de classe são os mesmos do mockup para facilitar a comparação.
   ====================================================================== */

body {
    background: var(--fundo);
    color: var(--tinta-corpo);
    font-family: var(--f-ui);
    font-size: 14px;
    min-width: 1120px;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--f-disp);
    letter-spacing: -0.015em;
    color: var(--tinta);
}

/* ──────── RAIL ──────── */
.e-rail {
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    width: 80px;
    background: #fff;
    border-right: 1px solid var(--linha);
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 16px 0;
    z-index: 60;
}

.e-rail .mk {
    width: 44px;
    height: 44px;
    border-radius: 14px;
    background: var(--oliva-esc);
    color: var(--creme);
    display: grid;
    place-items: center;
    font-family: var(--f-disp);
    font-weight: 600;
    font-size: 15px;
    letter-spacing: -0.03em;
    margin-bottom: 22px;
    cursor: pointer;
}

.e-ri {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    display: grid;
    place-items: center;
    font-size: 22px;
    color: var(--tinta5);
    margin-bottom: 6px;
    position: relative;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
}

.e-ri:hover {
    background: var(--superficie-3);
    color: var(--tinta2);
}

.e-ri.on {
    background: var(--superficie-4);
    color: var(--oliva-esc);
}

.e-ri.on::before {
    content: "";
    position: absolute;
    left: -16px;
    top: 13px;
    width: 3px;
    height: 22px;
    border-radius: 0 3px 3px 0;
    background: var(--terracota);
}

.e-ri .dica {
    position: absolute;
    left: 58px;
    white-space: nowrap;
    background: var(--oliva-esc);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 9px;
    padding: 6px 11px;
    font-size: 12px;
    font-weight: 500;
    color: var(--creme);
    z-index: 5;
    box-shadow: 0 12px 24px -12px rgba(43, 42, 34, 0.55);
    opacity: 0;
    transform: translateX(-4px);
    pointer-events: none;
    transition: 0.18s;
}

.e-ri .dica b {
    font-family: var(--f-dados);
    font-size: 10px;
    color: var(--mel);
    font-weight: 400;
    margin-left: 7px;
}

.e-ri:hover .dica {
    opacity: 1;
    transform: translateX(0);
}

.e-rail .pe {
    margin-top: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.e-rail .av {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: var(--oliva-esc);
    color: var(--creme);
    display: grid;
    place-items: center;
    font-weight: 600;
    font-size: 15px;
}

/* ──────── COLUNA ──────── */
.e-col {
    margin-left: 80px;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    min-width: 0;
}

/* ──────── CORPO ──────── */
.e-body {
    flex: 1;
    padding: 26px 26px 90px;
    position: relative;
}

.e-head {
    display: flex;
    align-items: flex-end;
    gap: 18px;
    margin-bottom: 22px;
}

.e-head h1 {
    font-family: var(--f-disp);
    font-size: 36px;
    font-weight: 300;
    letter-spacing: -0.03em;
    color: var(--oliva-esc);
    line-height: 1;
}

.e-head h1 em {
    font-style: normal;
    font-family: var(--f-dados);
    font-size: 15px;
    font-weight: 400;
    color: var(--terracota);
    vertical-align: super;
    margin-left: 10px;
}

.e-head p {
    font-size: 12.5px;
    color: var(--tinta4);
    margin-top: 9px;
}

.e-head .dir {
    margin-left: auto;
    display: flex;
    gap: 10px;
}

/* ──────── BOTÕES ──────── */
.btn-e {
    height: 42px;
    border-radius: 12px;
    padding: 0 17px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13.5px;
    font-weight: 600;
    font-family: var(--f-ui);
    border: 1px solid var(--linha-2);
    color: var(--tinta2);
    background: #fff;
    box-shadow: var(--sombra-s);
    cursor: pointer;
    white-space: nowrap;
    transition: 0.2s;
}

.btn-e i {
    font-size: 18px;
}

.btn-e:hover {
    border-color: var(--linha-3);
    color: var(--tinta);
}

.btn-e.pri {
    background: var(--oliva-esc);
    border-color: var(--oliva-esc);
    color: var(--creme);
    box-shadow: 0 14px 26px -16px rgba(77, 90, 43, 0.6);
}

.btn-e.pri:hover {
    background: var(--oliva-esc-2);
    border-color: var(--oliva-esc-2);
    color: #fff;
}

.btn-e.del {
    color: var(--terra-esc);
}

.btn-e.del:hover {
    border-color: rgba(184, 69, 47, 0.4);
}

.btn-e.peq {
    height: 34px;
    font-size: 12.5px;
    padding: 0 13px;
    border-radius: 10px;
}

.btn-e[disabled],
.btn-e.processando {
    opacity: 0.55;
    pointer-events: none;
}

/* ──────── GRADE DE GALERIAS ──────── */
.e-grade {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
    align-items: start;
}

.carde {
    position: relative;
    border-radius: 18px;
    overflow: hidden;
    border: 1px solid var(--linha);
    background: #fff;
    box-shadow: var(--sombra-s);
    cursor: pointer;
    transition: box-shadow 0.2s, border-color 0.2s;
}

.carde .capa {
    position: relative;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: var(--superficie-3);
}

.carde .capa img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.carde .capa::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(10, 9, 4, 0.42) 0%, rgba(10, 9, 4, 0) 38%, rgba(10, 9, 4, 0.82) 100%);
}

.carde .sel {
    position: absolute;
    left: 12px;
    top: 12px;
    width: 24px;
    height: 24px;
    border-radius: 8px;
    border: 1.5px solid rgba(255, 255, 255, 0.55);
    background: rgba(10, 9, 4, 0.35);
    z-index: 3;
    display: grid;
    place-items: center;
    color: transparent;
    font-size: 16px;
    cursor: pointer;
}

.carde .fer {
    position: absolute;
    right: 12px;
    top: 12px;
    display: flex;
    gap: 7px;
    z-index: 3;
    opacity: 0;
    transition: 0.2s;
}

.carde:hover .fer,
.carde.on .fer {
    opacity: 1;
}

.carde .fer span {
    width: 32px;
    height: 32px;
    border-radius: 10px;
    background: rgba(14, 12, 6, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.16);
    backdrop-filter: blur(3px);
    display: grid;
    place-items: center;
    font-size: 17px;
    color: #fff;
    cursor: pointer;
    transition: 0.2s;
}

.carde .fer span:hover {
    background: rgba(14, 12, 6, 0.74);
}

.carde .fer span.del {
    color: var(--coral);
}

.carde .base {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 14px 15px;
    z-index: 3;
}

.carde .base h4 {
    font-family: var(--f-disp);
    font-size: 17px;
    font-weight: 500;
    letter-spacing: -0.015em;
    color: var(--creme);
    line-height: 1.2;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.carde .base h4.vazio {
    color: rgba(255, 248, 234, 0.55);
    font-style: italic;
    font-weight: 300;
}

.carde .base .meta {
    display: flex;
    align-items: center;
    gap: 9px;
    margin-top: 8px;
    font-family: var(--f-dados);
    font-size: 10px;
    letter-spacing: 0.06em;
    color: rgba(255, 248, 234, 0.66);
}

.carde .base .meta span {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 10px;
    color: inherit;
    line-height: 1.2;
}

.carde .base .meta .pt {
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: currentColor;
    opacity: 0.5;
    padding: 0;
}

.carde .base .meta .av {
    color: var(--mel);
}

.carde .base .meta .falta {
    color: var(--coral);
}

.carde:hover {
    border-color: var(--linha-3);
    box-shadow: var(--sombra-m);
}

.carde.on {
    border-color: var(--oliva-esc);
    box-shadow: 0 0 0 2px rgba(77, 90, 43, 0.55), 0 18px 32px -20px rgba(43, 42, 34, 0.45);
}

.carde.on .sel {
    background: var(--oliva-esc);
    border-color: var(--oliva-esc);
    color: var(--creme);
}

/* cartão de criação */
.e-novo {
    border: 1.5px dashed var(--linha-3);
    background: var(--superficie-2);
    border-radius: 18px;
    aspect-ratio: 16 / 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 7px;
    color: var(--tinta2);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.2s;
}

.e-novo i {
    font-size: 26px;
}

.e-novo:hover {
    border-color: var(--oliva-esc);
    color: var(--oliva-esc);
}

/* ──────── BARRA DE SELEÇÃO EM LOTE ──────── */
.e-lote {
    position: fixed;
    left: calc(50% + 40px);
    transform: translateX(-50%) translateY(20px);
    bottom: 26px;
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--oliva-esc);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 10px 12px 10px 18px;
    box-shadow: 0 24px 46px -22px rgba(43, 42, 34, 0.7);
    color: var(--creme);
    z-index: 70;
    opacity: 0;
    pointer-events: none;
    transition: 0.25s;
}

.e-lote.ativo {
    opacity: 1;
    pointer-events: auto;
    transform: translateX(-50%) translateY(0);
}

.e-lote > i {
    font-size: 20px;
    color: var(--coral);
}

.e-lote b {
    font-size: 13px;
    font-weight: 600;
}

.e-lote small {
    font-family: var(--f-dados);
    font-size: 10.5px;
    color: rgba(255, 251, 240, 0.5);
    margin-left: 2px;
}

.e-lote .sep {
    width: 1px;
    height: 26px;
    background: rgba(255, 255, 255, 0.13);
    margin: 0 4px;
}

.e-lote .ac {
    height: 34px;
    border-radius: 10px;
    padding: 0 13px;
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 12.5px;
    font-weight: 600;
    background: rgba(255, 255, 255, 0.07);
    color: rgba(255, 251, 240, 0.85);
    cursor: pointer;
    transition: 0.2s;
}

.e-lote .ac i {
    font-size: 16px;
}

.e-lote .ac:hover {
    background: rgba(255, 255, 255, 0.14);
    color: #fff;
}

.e-lote .ac.del {
    color: var(--coral);
}

/* ──────── ABAS DE CONTEÚDO ──────── */
.e-abas {
    display: flex;
    gap: 9px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.e-aba {
    height: 44px;
    border-radius: 13px;
    padding: 0 16px;
    display: flex;
    align-items: center;
    gap: 10px;
    border: 1px solid var(--linha-2);
    background: #fff;
    font-size: 13.5px;
    font-weight: 600;
    color: var(--tinta3);
    cursor: pointer;
    transition: 0.2s;
}

.e-aba img {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    object-fit: cover;
}

.e-aba .n {
    font-family: var(--f-dados);
    font-size: 10px;
    font-weight: 400;
    background: rgba(43, 42, 34, 0.06);
    border-radius: 999px;
    padding: 2px 8px;
    color: var(--tinta4);
}

.e-aba:hover {
    border-color: var(--linha-3);
    color: var(--tinta);
}

.e-aba.on {
    background: var(--oliva-esc);
    border-color: var(--oliva-esc);
    color: var(--creme);
}

.e-aba.on .n {
    background: rgba(254, 220, 123, 0.2);
    color: var(--mel);
}

/* ──────── TRILHOS DE VÍDEO ──────── */
.e-trilho {
    margin-bottom: 24px;
}

.e-trilho-top {
    display: flex;
    align-items: center;
    gap: 11px;
    margin-bottom: 12px;
}

.e-trilho-top .grip {
    font-size: 19px;
    color: var(--tinta6);
    cursor: grab;
}

.e-trilho-top h3 {
    font-family: var(--f-disp);
    font-size: 18px;
    font-weight: 500;
    letter-spacing: -0.015em;
    color: var(--tinta);
    cursor: text;
}

.e-trilho-top .n {
    font-family: var(--f-dados);
    font-size: 10px;
    color: var(--tinta5);
    border: 1px solid var(--linha-2);
    border-radius: 999px;
    padding: 3px 9px;
}

.e-trilho-top .fer {
    margin-left: auto;
    display: flex;
    gap: 6px;
}

.e-trilho-top .fer span {
    width: 32px;
    height: 32px;
    border-radius: 10px;
    border: 1px solid var(--linha-2);
    background: #fff;
    display: grid;
    place-items: center;
    font-size: 17px;
    color: var(--tinta3);
    cursor: pointer;
    transition: 0.2s;
}

.e-trilho-top .fer span:hover {
    border-color: var(--linha-3);
    color: var(--tinta);
}

.e-trilho-top .fer span.del {
    color: var(--terra-esc);
}

.e-fila {
    display: flex;
    gap: 14px;
    align-items: flex-start;
    flex-wrap: wrap;
    min-height: 40px;
}

.vid {
    width: 214px;
    flex: none;
    position: relative;
}

.vid .thumb {
    position: relative;
    aspect-ratio: 16 / 10;
    border-radius: 13px;
    overflow: hidden;
    border: 1px solid var(--linha);
    background: var(--superficie-3);
}

.vid .thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.vid .thumb::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(10, 9, 4, 0) 55%, rgba(10, 9, 4, 0.7));
}

.vid .play {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(14, 12, 6, 0.42);
    border: 1px solid rgba(255, 255, 255, 0.22);
    display: grid;
    place-items: center;
    color: #fff;
    font-size: 17px;
    z-index: 2;
}

.vid .dur {
    position: absolute;
    right: 9px;
    bottom: 9px;
    font-family: var(--f-dados);
    font-size: 10px;
    color: #fff;
    z-index: 2;
}

.vid .ord {
    position: absolute;
    left: 9px;
    top: 9px;
    width: 22px;
    height: 22px;
    border-radius: 7px;
    background: rgba(14, 12, 6, 0.55);
    border: 1px solid rgba(255, 255, 255, 0.14);
    color: #fff;
    display: grid;
    place-items: center;
    font-family: var(--f-dados);
    font-size: 10px;
    z-index: 2;
    cursor: grab;
}

.vid .fer {
    position: absolute;
    right: 9px;
    top: 9px;
    display: flex;
    gap: 6px;
    z-index: 3;
    opacity: 0;
    transition: 0.2s;
}

.vid:hover .fer {
    opacity: 1;
}

.vid .fer span {
    width: 30px;
    height: 30px;
    border-radius: 9px;
    background: rgba(14, 12, 6, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.16);
    backdrop-filter: blur(3px);
    display: grid;
    place-items: center;
    font-size: 16px;
    color: #fff;
    cursor: pointer;
}

.vid .fer span:hover {
    background: rgba(14, 12, 6, 0.74);
}

.vid .fer span.del {
    color: var(--coral);
}

.vid p {
    font-size: 13px;
    font-weight: 600;
    margin-top: 10px;
    color: var(--tinta-corpo);
    cursor: text;
}

.vid small {
    font-family: var(--f-dados);
    font-size: 10px;
    color: var(--tinta5);
    display: block;
    margin-top: 5px;
    cursor: text;
    line-height: 1.4;
}

.vid small.falta {
    color: var(--terra-esc);
}

.e-add {
    width: 214px;
    flex: none;
    aspect-ratio: 16 / 10;
    border-radius: 13px;
    border: 1.5px dashed var(--linha-3);
    background: var(--superficie-2);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 7px;
    color: var(--tinta2);
    font-size: 12.5px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.2s;
}

.e-add i {
    font-size: 25px;
}

.e-add:hover {
    border-color: var(--oliva-esc);
    color: var(--oliva-esc);
}

/* ──────── ESTADOS ──────── */
.e-vazio {
    border: 1.5px dashed var(--linha-2);
    border-radius: var(--r-g);
    padding: 54px 20px;
    text-align: center;
    color: var(--tinta5);
    font-size: 13px;
    grid-column: 1 / -1;
}

.e-vazio i {
    font-size: 30px;
    display: block;
    margin: 0 auto 10px;
    color: var(--tinta6);
}

.e-carregando {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.e-esqueleto {
    aspect-ratio: 16 / 10;
    border-radius: 18px;
    background: linear-gradient(100deg, #f7f0de 30%, #eee4cb 50%, #f7f0de 70%);
    background-size: 240% 100%;
    animation: e-brilho 1.3s linear infinite;
}

@keyframes e-brilho {
    from { background-position: 140% 0; }
    to { background-position: -40% 0; }
}

/* ──────── FOLHA (tela cheia sobre o painel) ──────── */
.e-folha {
    position: fixed;
    inset: 0;
    z-index: 80;
    background: rgba(43, 42, 34, 0.32);
    backdrop-filter: blur(5px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s;
    display: grid;
    place-items: center;
    padding: 26px;
}

.e-folha.ativo {
    opacity: 1;
    pointer-events: auto;
}

.e-folha-caixa {
    background: var(--fundo);
    border-radius: 20px;
    border: 1px solid var(--linha);
    box-shadow: var(--sombra-g);
    width: 100%;
    max-width: 1180px;
    max-height: 100%;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.e-folha-top {
    background: #fff;
    border-bottom: 1px solid var(--linha);
    padding: 16px 20px;
    display: flex;
    align-items: center;
    gap: 14px;
    flex: none;
}

.e-folha-top h2 {
    font-family: var(--f-disp);
    font-size: 21px;
    font-weight: 500;
    letter-spacing: -0.02em;
}

.e-folha-top .dir {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 10px;
}

.e-folha-corpo {
    padding: 20px;
    overflow-y: auto;
    flex: 1;
}

.e-fechar {
    width: 36px;
    height: 36px;
    border-radius: 11px;
    border: 1px solid var(--linha-2);
    background: #fff;
    display: grid;
    place-items: center;
    font-size: 18px;
    color: var(--tinta3);
    cursor: pointer;
    flex: none;
    transition: 0.2s;
}

.e-fechar:hover {
    border-color: var(--linha-3);
    color: var(--tinta);
}

/* ──────── GAVETA (modal do canto) ──────── */
.e-gaveta {
    position: fixed;
    right: 20px;
    bottom: 20px;
    width: calc(100% - 40px);
    max-width: 430px;
    background: #fff;
    border: 1px solid var(--linha);
    border-radius: var(--r-g);
    box-shadow: var(--sombra-g);
    padding: 20px;
    z-index: 90;
    max-height: calc(100vh - 40px);
    overflow-y: auto;
    opacity: 0;
    transform: translateY(24px);
    pointer-events: none;
    transition: 0.3s ease-in-out;
}

.e-gaveta.ativo {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.e-gaveta h3 {
    font-family: var(--f-disp);
    font-size: 18px;
    font-weight: 500;
    margin-bottom: 16px;
}

.e-gaveta .e-fechar {
    position: absolute;
    right: 14px;
    top: 14px;
}

/* ──────── FORMULÁRIOS ──────── */
.campo {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--tinta5);
}

.campo input[type="text"],
.campo input[type="url"],
.campo input[type="email"],
.campo input[type="password"],
.campo input[type="number"],
.campo textarea,
.campo select {
    height: 44px;
    border-radius: 11px;
    border: 1px solid var(--linha-2);
    background: #fff;
    padding: 0 13px;
    font-size: 13.5px;
    font-weight: 500;
    color: var(--tinta-corpo);
    letter-spacing: 0;
    text-transform: none;
    font-family: var(--f-ui);
    transition: 0.2s;
}

.campo textarea {
    height: auto;
    min-height: 96px;
    padding: 11px 13px;
    line-height: 1.6;
    resize: vertical;
}

.campo input:focus,
.campo textarea:focus,
.campo select:focus {
    border-color: var(--oliva-esc);
    box-shadow: 0 0 0 3px rgba(77, 90, 43, 0.08);
}

.campo input::placeholder,
.campo textarea::placeholder {
    color: var(--tinta6);
    font-weight: 400;
}

.e-resposta {
    font-size: 12.5px;
    color: var(--tinta4);
}

.e-resposta:empty {
    display: none;
}

.e-resposta.erro {
    color: var(--terra-esc) !important;
    font-weight: 600;
}

.e-resposta.sucesso {
    color: var(--oliva) !important;
    font-weight: 600;
}

/* área de arrastar arquivo */
.e-solta {
    border: 1.5px dashed var(--linha-3);
    border-radius: var(--r-m);
    padding: 30px 20px;
    text-align: center;
    cursor: pointer;
    background: var(--superficie-2);
    transition: 0.2s;
}

.e-solta:hover,
.e-solta.drag-over {
    border-color: var(--oliva-esc);
    background: #fff;
}

.e-solta i {
    font-size: 30px;
    color: var(--tinta5);
    display: block;
    margin: 0 auto 10px;
}

.e-solta b {
    font-size: 13.5px;
    font-weight: 600;
    color: var(--tinta-corpo);
    display: block;
}

.e-solta small {
    font-size: 11.5px;
    color: var(--tinta5);
    display: block;
    margin-top: 4px;
}

.e-solta .arquivo {
    font-family: var(--f-dados);
    font-size: 11px;
    color: var(--terracota);
    display: block;
    margin-top: 10px;
    word-break: break-all;
}

.e-solta .arquivo:empty {
    display: none;
}

/* ──────── GRADE DE FOTOS (folha da galeria) ──────── */
.e-fotos {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
    align-items: start;
}

.foto {
    position: relative;
    aspect-ratio: 16 / 10;
    border-radius: var(--r-m);
    overflow: hidden;
    border: 1px solid var(--linha);
    background: var(--superficie-3);
    cursor: grab;
}

.foto img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.foto .fer {
    position: absolute;
    right: 8px;
    top: 8px;
    display: flex;
    gap: 6px;
    opacity: 0;
    transition: 0.2s;
    z-index: 2;
}

.foto:hover .fer {
    opacity: 1;
}

.foto .fer span {
    width: 30px;
    height: 30px;
    border-radius: 9px;
    background: rgba(14, 12, 6, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.16);
    backdrop-filter: blur(3px);
    display: grid;
    place-items: center;
    font-size: 16px;
    color: #fff;
    cursor: pointer;
}

.foto .fer span.del {
    color: var(--coral);
}

.foto .fer span.capa.ativo {
    background: var(--mel);
    border-color: var(--mel);
    color: var(--oliva-esc);
    opacity: 1;
}

.foto:has(.capa.ativo) .fer {
    opacity: 1;
}

/* fora do hover, a foto de capa mostra só a estrela */
.foto .fer span.del {
    opacity: 0;
    transition: 0.2s;
}

.foto:hover .fer span.del {
    opacity: 1;
}

.foto .ord {
    position: absolute;
    left: 8px;
    top: 8px;
    height: 22px;
    min-width: 22px;
    padding: 0 6px;
    border-radius: 7px;
    background: rgba(14, 12, 6, 0.55);
    border: 1px solid rgba(255, 255, 255, 0.14);
    color: #fff;
    display: grid;
    place-items: center;
    font-family: var(--f-dados);
    font-size: 10px;
    z-index: 2;
}

.foto.dragging {
    opacity: 0.5;
}

.foto.drag-placeholder {
    border: 1.5px dashed var(--oliva-esc);
    background: rgba(77, 90, 43, 0.06);
    pointer-events: none;
}

/* ──────── NOTIFICAÇÃO ──────── */
.notificacao {
    top: 20px;
    border-radius: var(--r-m);
    border: 1px solid var(--linha);
    border-left: 4px solid var(--oliva-esc);
    box-shadow: var(--sombra-m);
    font-family: var(--f-ui);
}

.notificacao.sucesso {
    background: #fff;
    border-left: 4px solid var(--oliva);
}

.notificacao.erro {
    background: #fff;
    border-left: 4px solid var(--terra-esc);
}

.notificacao.info {
    background: #fff;
    border-left: 4px solid var(--terracota);
}

.notificacao.aviso {
    background: #fff;
    border-left: 4px solid var(--mel);
}

h4.notificao-titulo {
    font-family: var(--f-disp);
    font-weight: 500;
    color: var(--tinta);
}

.notificacao-detalhes {
    color: var(--tinta4);
}

/* ──────── UTILIDADES ──────── */
.e-linha {
    display: flex;
    align-items: center;
    gap: 12px;
}

.e-fim {
    margin-left: auto;
}

.e-nota {
    font-size: 12px;
    color: var(--tinta5);
}

/* ──────── EDIÇÃO EM LINHA ──────── */
.inline-editar {
    width: 100%;
    margin-top: 10px;
    border-radius: 9px;
    border: 1px solid var(--oliva-esc);
    background: #fff;
    padding: 7px 9px;
    font-size: 13px;
    font-weight: 600;
    font-family: var(--f-ui);
    color: var(--tinta-corpo);
    box-shadow: 0 0 0 3px rgba(77, 90, 43, 0.08);
    resize: vertical;
}

.inline-editar.titulo {
    width: auto;
    min-width: 320px;
    margin-top: 0;
    font-family: var(--f-disp);
    font-size: 18px;
    font-weight: 500;
}

/* ──────── ARRASTAR (SortableJS) ──────── */
.sortable-ghost {
    opacity: 0.35;
}

.sortable-ghost .thumb {
    border: 1.5px dashed var(--oliva-esc);
}

.sortable-chosen {
    opacity: 0.9;
}

.sortable-drag {
    box-shadow: var(--sombra-g);
}

.e-fila.recebendo {
    outline: 1.5px dashed var(--linha-3);
    outline-offset: 6px;
    border-radius: var(--r-m);
}

.e-rail .av {
    cursor: pointer;
    transition: 0.2s;
}

.e-rail .av:hover {
    background: var(--oliva-esc-2);
}

/* ──────── EBOOKS ──────── */
.e-regua {
    display: flex;
    border-top: 1px solid var(--linha);
    border-bottom: 1px solid var(--linha);
    margin-bottom: 22px;
}

.e-regua div {
    flex: 1;
    padding: 14px 20px;
    border-left: 1px solid var(--linha);
}

.e-regua div:first-child {
    border-left: 0;
    padding-left: 0;
}

.e-regua b {
    display: block;
    font-family: var(--f-disp);
    font-size: 30px;
    font-weight: 300;
    letter-spacing: -0.03em;
    color: var(--oliva-esc);
    line-height: 1.1;
}

.e-regua span {
    font-family: var(--f-dados);
    font-size: 10px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--tinta5);
}

.e-grade.livros {
    grid-template-columns: repeat(5, 1fr);
}

/* capas em pé, na proporção dos arquivos (600x849) */
.livros .carde .capa,
.livros .e-novo,
.livros .e-esqueleto {
    aspect-ratio: 600 / 849;
}

.livros .carde .capa {
    display: grid;
    place-items: center;
    color: var(--tinta6);
    font-size: 34px;
}

.livros .carde .base .meta.origem {
    margin-top: 5px;
    color: rgba(255, 248, 234, 0.5);
}

.carde.oculto .capa img {
    filter: grayscale(1);
    opacity: 0.6;
}

.e-soltas {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.e-solta.compacta {
    padding: 18px 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 150px;
}

.e-solta.com-previa {
    padding: 8px;
}

.e-solta.com-previa > :not(img):not(input) {
    display: none;
}

.e-solta #capa-previa {
    height: 150px;
    aspect-ratio: 600 / 849;
    object-fit: cover;
    border-radius: 8px;
    display: block;
}

.e-solta #capa-previa[hidden] {
    display: none;
}

.e-marcar {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13.5px;
    font-weight: 500;
    color: var(--tinta-corpo);
    cursor: pointer;
}

.e-marcar input {
    width: 17px;
    height: 17px;
    accent-color: var(--oliva-esc);
}
