:root {
    color-scheme: dark;
    --bg: #060606;
    --panel: #121212;
    --panel-2: #171717;
    --text: #f3efe8;
    --muted: #b5b0a8;
    --accent: #ff7a1a;
    --accent-strong: #d85b00;
    --border: rgba(255, 255, 255, 0.12);
    --shadow: 0 20px 50px rgba(0, 0, 0, 0.35);
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: "Inter", "Segoe UI", Roboto, Arial, sans-serif;
    background: linear-gradient(135deg, #050505 0%, #0f0f0f 100%);
    color: var(--text);
    line-height: 1.6;
}

a {
    color: inherit;
    text-decoration: none;
}

header {
    position: sticky;
    top: 0;
    z-index: 20;
    padding: 1rem 1.25rem;
    background: rgba(6, 6, 6, 0.8);
    backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--border);
}

header .wrap,
main {
    max-width: 1200px;
    margin: 0 auto;
}

header .wrap {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

header h1 {
    margin: 0;
    font-size: clamp(1.2rem, 2vw, 1.6rem);
    letter-spacing: 0.24em;
    text-transform: uppercase;
}

nav ul {
    display: flex;
    flex-wrap: wrap;
    gap: 0.9rem;
    list-style: none;
    padding: 0;
    margin: 0;
}

nav a {
    padding: 0.5rem 0.75rem;
    border-radius: 999px;
    transition: background 0.2s ease, color 0.2s ease;
}

nav a:hover {
    background: rgba(255, 122, 26, 0.16);
    color: #ffb36b;
}

main {
    padding: 2rem 1.25rem 4rem;
}

.hero,
.panel {
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.04), rgba(255, 122, 26, 0.06));
    border: 1px solid var(--border);
    border-radius: 10px;
    box-shadow: var(--shadow);
}

.hero {
    display: grid;
    grid-template-columns: 1.25fr 0.75fr;
    gap: 1.25rem;
    padding: 2rem;
    margin-bottom: 1.5rem;
}

.eyebrow {
    display: inline-block;
    margin-bottom: 0.5rem;
    color: var(--accent);
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.2em;
    text-transform: uppercase;
}

.hero h2 {
    margin: 0 0 0.7rem;
    font-size: clamp(1.8rem, 3.1vw, 2.8rem);
    line-height: 1.1;
}

.hero p {
    margin: 0;
    color: var(--muted);
    max-width: 60ch;
}

.pill-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.7rem;
    margin-top: 1rem;
}

.pill {
    padding: 0.55rem 0.8rem;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.04);
    color: #f2d7c3;
    font-size: 0.9rem;
}

.panel {
    padding: 1.25rem;
    margin-bottom: 1.25rem;
}

.panel.transparent {
    background: transparent;
    border: none;
    box-shadow: none;
}

.section-title {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.section-title h3 {
    margin: 0;
    font-size: 1.1rem;
}

.section-title span {
    color: var(--muted);
    font-size: 0.95rem;
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1rem;
}

.signature-card {
    position: relative;
    overflow: hidden;
    padding: 1.15rem;
    border-radius: 15px;
    border: 1px solid rgba(255, 122, 26, 0.22);
    background: linear-gradient(135deg, rgba(255, 122, 26, 0.12), rgba(255, 255, 255, 0.03));
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
    transition: transform 0.22s ease, border-color 0.22s ease;
}

.signature-card::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(120deg, transparent 0%, rgba(255, 255, 255, 0.01) 50%, transparent 100%);
    transform: translateX(-120%);
    transition: transform 0.6s ease;
}

.signature-card:hover {
    transform: translateY(-3px);
    border-color: rgba(255, 122, 26, 0.32);
    box-shadow: 0 10px 28px rgba(255, 122, 26, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.signature-card:hover::before {
    transform: translateX(120%);
}

.card-tag {
    display: inline-block;
    margin-bottom: 0.4rem;
    color: #ffb36b;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.signature-card h4 {
    margin: 0.3rem 0 0.45rem;
    font-size: 1.08rem;
}

.signature-card p {
    margin: 0;
    color: var(--muted);
    font-size: 0.96rem;
}

.project-media {
    display: grid;
    grid-template-columns: minmax(150px, 38%) 1fr;
    gap: 1rem;
    align-items: start;
    margin-top: 0.55rem;
}

.project-media > * {
    min-width: 0;
}

.project-media p {
    align-self: center;
}

.project-image {
    display: block;
    width: 100%;
    max-width: 100%;
    border-radius: 18px;
    object-fit: contain;
    object-position: center;
    height: 20vh;
    background: rgba(23, 23, 23, 0.03);
    margin: 1rem 0;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.18);
}

.signature-card.wide {
    grid-column: span 2;
}

.portfolio-grid.equal-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.signature-card.equal {
    grid-column: span 1;
}


.contact-form {
    display: grid;
    gap: 1rem;
}

.field {
    display: grid;
    gap: 0.45rem;
}

.remember-field {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    font-size: 0.95rem;
    color: var(--muted);
}

.remember-field input[type="checkbox"] {
    width: 1rem;
    height: 1rem;
    padding: 0;
    accent-color: var(--accent);
}

label {
    font-size: 0.95rem;
    color: #f2d7c3;
}

input,
textarea {
    width: 100%;
    padding: 0.9rem 1rem;
    border-radius: 14px;
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.04);
    color: var(--text);
    outline: none;
}

input:focus,
textarea:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(255, 122, 26, 0.18);
}

textarea {
    min-height: 120px;
    resize: vertical;
}

button {
    justify-self: start;
    padding: 0.85rem 1.25rem;
    border: none;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--accent), var(--accent-strong));
    color: #0b0b0b;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.2s ease, filter 0.2s ease;
}

.download-btn {
    display: inline-block;
    justify-self: start;
    margin-top: 0.9rem;
    padding: 0.85rem 1.25rem;
    border: none;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--accent), var(--accent-strong));
    color: #0b0b0b;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.2s ease, filter 0.2s ease;
}

button:hover {
    transform: translateY(-1px);
    filter: brightness(1.04);
}

button:disabled {
    cursor: wait;
    opacity: 0.9;
    transform: none;
    filter: brightness(0.95);
}

.transfer-submit-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.55rem;
    min-width: 9rem;
}

.transfer-submit-btn .loading-spinner {
    display: none;
    width: 0.95rem;
    height: 0.95rem;
    border: 2px solid rgba(0, 0, 0, 0.22);
    border-top-color: currentColor;
    border-radius: 50%;
    animation: transfer-spin 0.8s linear infinite;
}

.transfer-submit-btn.is-loading .loading-spinner {
    display: inline-block;
}

.transfer-iframe {
    display: none;
}

@keyframes transfer-spin {
    to {
        transform: rotate(360deg);
    }
}

.download-btn:hover {
    transform: translateY(-1px);
    filter: brightness(1.04);
}

.auth-toggle {
    display: flex;
    gap: 0.7rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.toggle-btn {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text);
    border: 1px solid var(--border);
}

.toggle-btn.active {
    background: linear-gradient(135deg, var(--accent), var(--accent-strong));
    color: #0b0b0b;
}

.auth-form {
    display: none;
}

.auth-form {
    display: none;
}

.auth-form.active-form {
    display: grid;
}

.form-error {
    min-height: 1.2rem;
    margin: 0;
    color: #ff8a5b;
    font-size: 0.95rem;
}

.otp-inputs {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 0.55rem;
}

.otp-box {
    width: 100%;
    text-align: center;
    font-size: 1.1rem;
    padding: 0.8rem 0.2rem;
}

.otp-title {
    margin: 0 0 0.75rem;
    color: var(--muted);
}

.site-footer {
    margin-top: 1rem;
    padding: 0 1.25rem 2rem;
    color: var(--muted);
}

.footer-wrap {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1.2rem;
    border-radius: 12px;
    border: 1px solid var(--border);
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.03), rgba(255, 122, 26, 0.07));
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) minmax(0, 1fr);
    gap: 1rem;
}

.footer-brand h2 {
    margin: 0;
    font-size: clamp(1.1rem, 2vw, 1.5rem);
    letter-spacing: 0.24em;
    text-transform: uppercase;
    color: var(--text);
}

.footer-brand p {
    margin: 0.55rem 0 0;
    max-width: 32ch;
}

.footer-nav h3,
.footer-contact h3 {
    margin: 0;
    font-size: 0.95rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #ffb36b;
}

.footer-nav ul {
    margin: 0.7rem 0 0;
    padding: 0;
    list-style: none;
    display: grid;
    gap: 0.45rem;
}

.footer-nav a,
.footer-contact a {
    color: var(--text);
    opacity: 0.88;
    transition: opacity 0.2s ease, color 0.2s ease;
}

.footer-nav a:hover,
.footer-contact a:hover {
    opacity: 1;
    color: #ffb36b;
}

.footer-contact p {
    margin: 0.7rem 0 0.25rem;
}

.footer-copy {
    max-width: 1200px;
    margin: 0.8rem auto 0;
    text-align: center;
    font-size: 0.92rem;
}

.admin-table-wrap {
    width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    margin-top: 1rem;
}

.admin-table {
    width: 100%;
    min-width: 560px;
    border-collapse: collapse;
}

.admin-table th,
.admin-table td {
    padding: 0.8rem 0.6rem;
    border-bottom: 1px solid var(--border);
    text-align: left;
}

.admin-table th {
    color: #ffb36b;
}

.table-actions {
    width: 1%;
    white-space: nowrap;
}

.inline-form {
    margin: 0;
}

.danger-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.55rem 0.8rem;
    border: 1px solid rgba(255, 120, 120, 0.35);
    border-radius: 999px;
    background: linear-gradient(135deg, #4a1515, #7a2121);
    color: #ffd6d6;
    font-weight: 700;
}

.danger-btn:hover {
    filter: brightness(1.08);
}

.trash-icon {
    width: 0.95rem;
    height: 0.95rem;
}

.transfer-usage {
    margin-top: 1rem;
    padding: 0.95rem;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.03);
}

.transfer-usage-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.6rem;
    color: var(--muted);
}

.transfer-usage-head strong {
    color: var(--text);
}

.transfer-progress {
    display: block;
    width: 100%;
    height: 0.8rem;
    border-radius: 999px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.1);
}

.transfer-progress::-webkit-progress-bar {
    background: rgba(255, 255, 255, 0.1);
}

.transfer-progress::-webkit-progress-value {
    background: linear-gradient(135deg, var(--accent), #ffb36b);
}

.transfer-progress::-moz-progress-bar {
    background: linear-gradient(135deg, var(--accent), #ffb36b);
}

.query-box {
    min-height: 120px;
    font-family: "SFMono-Regular", Consolas, monospace;
}

.query-output {
    white-space: pre-wrap;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border);
    border-radius: 16px;
    overflow: auto;
}

.error {
    color: #ff8a5b;
    margin-top: 0.7rem;
}

.success {
    color: #8ed18e;
    margin-top: 0.7rem;
}

.limit-note {
    margin: 0.6rem 0 0;
    padding: 0.85rem 1rem;
    border: 1px solid rgba(255, 122, 26, 0.35);
    border-radius: 12px;
    background: rgba(255, 122, 26, 0.1);
    color: #ffcf9f;
}

@media (max-width: 760px) {
    input,
    textarea,
    select {
        font-size: 16px;
    }

    header .wrap {
        flex-direction: column;
        align-items: flex-start;
    }

    .hero {
        grid-template-columns: 1fr;
        padding: 1.25rem;
    }

    .portfolio-grid {
        grid-template-columns: 1fr;
    }

    .signature-card.wide {
        grid-column: auto;
    }

    .signature-card.equal {
        grid-column: auto;
    }

    .portfolio-grid.equal-grid {
        grid-template-columns: 1fr;
    }

    .project-media {
        grid-template-columns: 1fr;
    }

    .footer-wrap {
        grid-template-columns: 1fr;
    }
}
