/* marvel-comics.css – Twenty Twenty child theme compatible */

/* ── Haku ─────────────────────────────────────────────────── */

.marvel-search {
    margin: 2em 0;
}

.marvel-search-fields {
    display: flex;
    flex-wrap: wrap;
    gap: 1.2em;
    margin-bottom: 1em;
}

.marvel-search-fields label {
    display: flex;
    flex-direction: column;
    gap: 0.3em;
    font-size: 0.95em;
    font-weight: 600;
}

.marvel-search-fields input[type="text"],
.marvel-search-fields input[type="number"] {
    padding: 0.45em 0.7em;
    border: 1px solid #767676;
    border-radius: 2px;
    font-size: 1em;
    width: 14em;
}

.marvel-search button[type="submit"] {
    padding: 0.55em 1.8em;
    background: #000;
    color: #fff;
    border: none;
    border-radius: 2px;
    font-size: 1em;
    cursor: pointer;
    letter-spacing: 0.03em;
}

.marvel-search button[type="submit"]:hover {
    background: #333;
}

/* ── Listaus ──────────────────────────────────────────────── */

.marvel-back-search,
.marvel-count {
    margin: 0.5em 0;
    font-size: 0.9em;
}

.marvel-list {
    overflow-x: auto;
    margin: 1em 0;
}

.marvel-list table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9em;
}

.marvel-list th,
.marvel-list td {
    padding: 0.5em 0.75em;
    border-bottom: 1px solid #e0e0e0;
    text-align: left;
    vertical-align: top;
}

.marvel-list th {
    background: #f2f2f2;
    font-weight: 700;
    white-space: nowrap;
}

.marvel-list tbody tr:hover td {
    background: #fafafa;
}

.marvel-pagination {
    display: flex;
    gap: 1.2em;
    align-items: center;
    justify-content: center;
    margin: 1.5em 0;
    font-size: 0.95em;
}

.marvel-pagination a {
    text-decoration: none;
    font-weight: 600;
}

/* ── Tarinakortti ─────────────────────────────────────────── */

.marvel-story {
    max-width: 860px;
    margin: 0 auto;
}

.marvel-story-header {
    text-align: center;
    padding-bottom: 1.5em;
    margin-bottom: 1.5em;
    border-bottom: 1px solid #e0e0e0;
}

.marvel-title {
    font-size: 1.5em;
    margin-bottom: 0.2em;
}

.marvel-alt-title {
    color: #555;
    font-style: italic;
    margin-top: 0;
}

.marvel-creators {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 0.25em 1.2em;
    max-width: 480px;
    margin: 1.2em auto 0;
    text-align: left;
}

.marvel-creators dt {
    font-weight: 700;
    white-space: nowrap;
}

.marvel-creators dd {
    margin: 0;
}

.marvel-notes {
    margin-top: 1em;
    font-size: 0.88em;
    color: #444;
}

.marvel-story-issues {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2em;
    margin-bottom: 1.5em;
}

.marvel-orig,
.marvel-fi {
    background: #f7f7f7;
    border-radius: 3px;
    padding: 1.2em 1.4em;
}

.marvel-orig h3,
.marvel-fi h3 {
    margin: 0 0 0.8em;
    font-size: 0.85em;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #555;
}

.marvel-cover {
    display: block;
    max-width: 100%;
    height: auto;
    margin: 0 auto 1.2em;
    box-shadow: 0 2px 8px rgba(0,0,0,0.18);
    border-radius: 2px;
}

.marvel-orig p,
.marvel-fi p {
    margin: 0.3em 0;
    font-size: 0.95em;
}

.marvel-code {
    color: #666;
    font-size: 0.9em;
}

.marvel-back {
    margin-top: 0.5em;
    font-size: 0.9em;
}

/* ── Viesti-elementit ─────────────────────────────────────── */

.marvel-error,
.marvel-noresults {
    padding: 0.8em 1em;
    border-left: 4px solid #ccc;
    background: #f9f9f9;
    font-size: 0.95em;
}

/* ── Mobiili ──────────────────────────────────────────────── */

@media (max-width: 640px) {
    .marvel-story-issues {
        grid-template-columns: 1fr;
    }

    .marvel-creators {
        max-width: 100%;
    }

    .marvel-search-fields input[type="text"],
    .marvel-search-fields input[type="number"] {
        width: 100%;
    }
}
