@font-face {
    font-family: "SyPhotosDisplay";
    src: url("/fonts/Montserrat-ExtraBold.ttf") format("truetype");
    font-weight: 800;
    font-style: normal;
    font-display: swap;
}

:root {
    color-scheme: dark;
    --bg: #0b0d10;
    --bg-elevated: #10151d;
    --surface: #151a21;
    --surface-strong: #1a212b;
    --surface-soft: rgba(21, 26, 33, 0.82);
    --border: #273140;
    --border-strong: #334155;
    --text-primary: #f8fafc;
    --text-secondary: #a0aec0;
    --text-muted: #718096;
    --accent-cyan: #40e0ff;
    --accent-violet: #7c3aed;
    --accent-gradient: linear-gradient(135deg, #40e0ff, #7c3aed);
    --shadow-sm: 0 12px 32px rgba(0, 0, 0, 0.22);
    --shadow-md: 0 20px 48px rgba(0, 0, 0, 0.32);
    --shadow-glow: 0 0 0 1px rgba(64, 224, 255, 0.14), 0 22px 60px rgba(124, 58, 237, 0.28);
    --radius-sm: 12px;
    --radius-md: 16px;
    --radius-lg: 20px;
    --transition-fast: all 0.2s ease;
    --font-heading: "SyPhotosDisplay", "Segoe UI", sans-serif;
    --font-body: "Microsoft YaHei", "PingFang SC", "Segoe UI", sans-serif;
}

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

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    background:
        radial-gradient(circle at top left, rgba(64, 224, 255, 0.09), transparent 24%),
        radial-gradient(circle at top right, rgba(124, 58, 237, 0.13), transparent 28%),
        linear-gradient(180deg, #0b0d10 0%, #0d1218 100%);
    color: var(--text-primary);
    font-family: var(--font-body);
    line-height: 1.7;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    margin-top: 0;
    color: var(--text-primary);
    font-family: var(--font-heading);
    font-weight: 800;
    letter-spacing: -0.02em;
}

p,
li,
label,
small,
span {
    color: var(--text-secondary);
}

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

img {
    max-width: 100%;
}

button,
input,
select,
textarea {
    appearance: none;
    -webkit-appearance: none;
    font: inherit;
}

button,
.btn,
input[type="submit"],
input[type="button"],
a.btn {
    border: 1px solid transparent;
    border-radius: var(--radius-sm);
    background: var(--accent-gradient);
    color: #f8fafc;
    box-shadow: 0 10px 30px rgba(64, 224, 255, 0.18);
    transition: var(--transition-fast);
}

button:hover,
.btn:hover,
input[type="submit"]:hover,
input[type="button"]:hover,
a.btn:hover {
    transform: scale(1.02) translateY(-1px);
    box-shadow: 0 0 24px rgba(64, 224, 255, 0.18), 0 18px 40px rgba(124, 58, 237, 0.28);
}

button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
a:focus-visible {
    outline: 2px solid rgba(64, 224, 255, 0.8);
    outline-offset: 2px;
}

input,
select,
textarea {
    width: 100%;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: rgba(11, 13, 16, 0.88);
    color: var(--text-primary);
    transition: var(--transition-fast);
}

input::placeholder,
textarea::placeholder {
    color: var(--text-muted);
}

input:hover,
select:hover,
textarea:hover,
input:focus,
select:focus,
textarea:focus {
    border-color: rgba(64, 224, 255, 0.55);
    box-shadow: 0 0 0 4px rgba(64, 224, 255, 0.08);
    outline: none;
}

table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: var(--surface);
    box-shadow: var(--shadow-sm);
}

thead th {
    background: rgba(124, 58, 237, 0.12);
    color: var(--text-primary);
}

th,
td {
    padding: 16px 18px;
    border-bottom: 1px solid rgba(39, 49, 64, 0.72);
    color: var(--text-secondary);
    text-align: left;
}

tbody tr {
    transition: var(--transition-fast);
}

tbody tr:hover {
    background: rgba(64, 224, 255, 0.05);
}

.photolist-card,
.login-card,
.register-form,
.search-container,
.featured-carousel,
.photolist-filter-panel,
.photolist-header,
.announcement-content,
.photolist-empty,
.photolist-error,
.photolist-loading,
.footer-content > div {
    border: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
}

.photolist-card,
.login-card,
.register-form,
.search-container,
.featured-carousel,
.photolist-filter-panel,
.announcement-content,
.footer-content > div {
    background: linear-gradient(180deg, rgba(26, 33, 43, 0.96), rgba(21, 26, 33, 0.96));
}

.photolist-card,
.login-card,
.register-form,
.search-container,
.featured-carousel,
.photolist-filter-panel,
.photolist-header,
.announcement-content,
.footer-content > div,
table {
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.photolist-card:hover,
.login-card:hover,
.register-form:hover,
.search-container:hover,
.featured-carousel:hover,
.photolist-filter-panel:hover,
.photolist-header:hover,
.announcement-content:hover,
.footer-content > div:hover,
table:hover {
    transform: scale(1.02) translateY(-2px);
    border-color: rgba(64, 224, 255, 0.42);
    box-shadow: var(--shadow-glow);
}

.photolist-card {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius-md);
}

.photolist-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 35%, rgba(11, 13, 16, 0.78) 100%);
    opacity: 0.92;
    pointer-events: none;
}

.photolist-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.2s ease;
}

.photolist-card:hover img {
    transform: scale(1.05);
}

.photolist-card-body {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 1;
    padding: 18px;
}

.photolist-card-title {
    margin: 0 0 8px;
    color: #fff;
    font-family: var(--font-heading);
    font-size: 1rem;
    line-height: 1.35;
}

.photolist-card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    font-size: 0.82rem;
}

.photolist-card-meta span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: rgba(248, 250, 252, 0.76);
}

::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: #0f1318;
}

::-webkit-scrollbar-thumb {
    border-radius: 999px;
    background: linear-gradient(180deg, rgba(64, 224, 255, 0.65), rgba(124, 58, 237, 0.75));
}
