/* PixQR – czarno-biały, responsywny layout */

*,
*::before,
*::after {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: #000000;
    color: #f5f5f5;
}

a {
    color: #ffffff;
    text-decoration: underline;
}

a:hover {
    text-decoration: none;
}

.page {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.header {
    padding: 14px 18px;
    border-bottom: 1px solid #ffffff33;
    background: #000000;
}

.brand {
    display: flex;
    align-items: center;
    gap: 10px;
}

.brand-logo {
    width: 30px;
    height: 30px;
    border-radius: 8px;
    border: 1px solid #ffffff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.brand-text {
    display: flex;
    flex-direction: column;
}

.brand-name {
    font-weight: 600;
    letter-spacing: 0.04em;
}

.brand-subtitle {
    font-size: 11px;
    color: #cccccc;
}

.main {
    flex: 1;
    display: flex;
    justify-content: center;
    padding: 22px 14px 30px;
}

.card {
    width: 100%;
    max-width: 640px;
    background: #000000;
    border-radius: 18px;
    border: 1px solid #ffffff33;
    padding: 18px 16px 22px;
    box-shadow: 0 18px 40px #000000dd;
}

h1 {
    margin: 0 0 8px;
    font-size: 22px;
}

.intro {
    margin-top: 0;
    margin-bottom: 18px;
    font-size: 14px;
    color: #dddddd;
}

.field-group {
    margin-bottom: 14px;
}

.field-label {
    display: block;
    font-size: 13px;
    margin-bottom: 4px;
}

.field-label.small {
    font-size: 12px;
    color: #dddddd;
}

.text-input,
.select-input {
    width: 100%;
    padding: 9px 11px;
    border-radius: 8px;
    border: 1px solid #ffffff55;
    background: #000000;
    color: #f5f5f5;
    font-size: 14px;
    outline: none;
}

.text-input:focus,
.select-input:focus {
    border-color: #ffffff;
    box-shadow: 0 0 0 1px #ffffff55;
}

.checkbox-row {
    margin-top: 6px;
}

.checkbox {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: #e5e5e5;
}

.checkbox input[type="checkbox"] {
    width: 14px;
    height: 14px;
    accent-color: #ffffff;
}

.buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
    margin-bottom: 6px;
}

.btn {
    border-radius: 999px;
    border: 1px solid #ffffff77;
    padding: 8px 16px;
    font-size: 14px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: transform 0.06s ease, box-shadow 0.06s ease, background-color 0.1s ease, color 0.1s ease;
    white-space: nowrap;
    background: #000000;
    color: #ffffff;
}

.btn-primary {
    background: #ffffff;
    color: #000000;
    border-color: #ffffff;
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 18px #ffffff44;
}

.btn-success {
    background: #000000;
    color: #ffffff;
}

.btn-success:hover {
    background: #ffffff;
    color: #000000;
}

.btn-ghost {
    background: transparent;
}

.btn-ghost:hover {
    background: #111111;
}

#previewWrapper {
    margin-top: 16px;
    border-radius: 14px;
    border: 1px dashed #ffffff55;
    padding: 16px;
    background: #000000;
    text-align: center;
}

#resultCanvas {
    max-width: 100%;
    height: auto;
    image-rendering: pixelated;
}

.hint {
    margin: 8px 0 0;
    font-size: 13px;
    color: #b3b3b3;
}

.qr-temp {
    position: absolute;
    left: -9999px;
    top: -9999px;
    visibility: hidden;
}

.info {
    margin-top: 16px;
    font-size: 13px;
    color: #cccccc;
}

.info summary {
    cursor: pointer;
    font-weight: 500;
    color: #ffffff;
    margin-bottom: 6px;
}

.info code {
    background: #111111;
    padding: 2px 5px;
    border-radius: 4px;
    font-size: 12px;
}

.info pre {
    background: #111111;
    padding: 10px;
    border-radius: 8px;
    overflow-x: auto;
}

.footer {
    margin-top: 18px;
    font-size: 12px;
    text-align: center;
    color: #bbbbbb;
}

.footer .kofi {
    margin-top: 4px;
}

/* Responsywność */

@media (min-width: 640px) {
    .card {
        padding: 20px 22px 24px;
    }

    h1 {
        font-size: 24px;
    }

    .intro {
        font-size: 15px;
    }

    .buttons {
        gap: 10px;
    }
}
