* { box-sizing: border-box; margin: 0; padding: 0; }
html { color-scheme: dark; scrollbar-color: #555 var(--bg); }
body { min-height: 100vh; letter-spacing: 0; }
::selection { background: var(--text-main); color: var(--bg); }
a { color: inherit; text-decoration: none; }
a:focus-visible { outline: 2px solid var(--text-main); outline-offset: 5px; }
.navbar { position: fixed; inset: 0 0 auto; z-index: 10; height: 80px; background: var(--bg); border-bottom: 1px solid var(--border); }
.nav-content { max-width: 1280px; height: 100%; margin: auto; padding: 0 40px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.logo { display: inline-flex; flex-shrink: 0; }
.logo img { display: block; width: 160px; height: 32px; object-fit: contain; }
.btn-back { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 20px; border: 1px solid #444; border-radius: 999px; font-size: 14px; font-weight: 500; transition: color 160ms ease, background 160ms ease; }
.btn-back:hover { background: var(--text-main); color: var(--bg); }
.btn-back i { font-size: 18px; }
.container { max-width: 1280px; margin: auto; padding: 152px 40px 64px; }
.hero { margin-bottom: 64px; }
.badge { margin-bottom: 20px; font-size: 12px; color: var(--text-muted); text-transform: uppercase; }
.hero-title { font-size: 72px; font-weight: 700; line-height: 1.05; margin-bottom: 28px; letter-spacing: 0; }
.hero-title span { font-weight: 300; color: #67d8ed; }
.hero-subtitle { max-width: 620px; font-size: 18px; line-height: 1.65; color: var(--text-muted); }
.projects-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.project-card { --project-accent: #ffffff; min-width: 0; display: block; background: var(--surface); background: color-mix(in srgb, var(--project-accent) 5%, var(--surface)); border: 1px solid var(--border); border-radius: 4px; transition: background 180ms ease, border-color 180ms ease; }
.project-card[href="../gnet/"] { --project-accent: #00d2ff; }
.project-card[href="../ex/"] { --project-accent: #c084fc; }
.project-card[href="../drainwatch/"] { --project-accent: #34d399; }
.project-card[href="../hydroalert/"] { --project-accent: #60a5fa; }
.project-card[href="../space/"] { --project-accent: #fbbf24; }
.project-card[href="../bcc/"] { --project-accent: #7dd6a1; }
.project-card[href="../truthlens/"] { --project-accent: #38bdf8; }
.project-card[href="../viaje/"] { --project-accent: #a3e635; }
.project-card[href="../y2k38/"] { --project-accent: #ff997a; }
.project-card[href="../usls/"] { --project-accent: #6ee7a0; }
.project-card[href="../ccna2/"] { --project-accent: #67d8ed; }
.project-card[href="../quanti0216/"] { --project-accent: #c4a5ff; }
.project-card[href="../rssfeed/"] { --project-accent: #f6d76b; }
.project-card[href="../photorss/"] { --project-accent: #ff8daa; }
.project-card[href="../jsonfeed/"] { --project-accent: #ffc18a; }
.project-card[href="../webanim/"] { --project-accent: #7dd3fc; }
.project-card[href="../webanim/skyward/"] { --project-accent: #9bbcff; }
.project-card[href="../webanim/skyward+js/"] { --project-accent: #b0a0ff; }
.project-card[href="../hydroalert/mobile/"] { --project-accent: #5ee0cb; }
.project-card[href="../admin/"] { --project-accent: #f0abfc; }
.project-card:hover { background: #171717; background: color-mix(in srgb, var(--project-accent) 10%, var(--surface)); border-color: var(--project-accent); }
.project-card:focus-visible { outline-color: var(--project-accent); }
.card-content { padding: 28px; display: flex; flex-direction: column; height: 100%; }
.card-header { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-bottom: 32px; }
.icon-box { display: flex; align-items: center; justify-content: center; width: 48px; height: 48px; border-radius: 6px; font-size: 28px; color: var(--project-accent); background: color-mix(in srgb, var(--project-accent) 12%, transparent); }
.status-badge { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--text-muted); }
.status-badge i { font-size: 6px; }
.status-badge.online i { color: #34d399; }
.card-body { flex-grow: 1; }
.card-body h2 { font-size: 24px; line-height: 1.2; font-weight: 500; margin-bottom: 12px; overflow-wrap: anywhere; }
.card-body p { font-size: 15px; line-height: 1.65; color: var(--text-muted); margin-bottom: 28px; }
.card-footer { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: auto; padding-top: 20px; border-top: 1px solid var(--border); }
.tags { display: flex; flex-wrap: wrap; gap: 6px 12px; color: var(--text-muted); font-size: 12px; }
.action { flex-shrink: 0; width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; font-size: 24px; color: var(--project-accent); }
.footer { border-top: 1px solid var(--border); color: var(--text-muted); padding: 32px 40px; text-align: center; font-size: 13px; }
@media (max-width: 1023px) {
    .projects-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 639px) {
    .navbar { height: 64px; }
    .nav-content { padding: 0 24px; gap: 12px; }
    .logo img { width: 120px; height: 24px; }
    .btn-back { font-size: 12px; padding: 0 12px; }
    .container { padding: 112px 24px 48px; }
    .hero { margin-bottom: 40px; }
    .hero-title { font-size: 48px; }
    .hero-subtitle { font-size: 16px; }
    .projects-grid { grid-template-columns: minmax(0, 1fr); gap: 12px; }
    .card-content { padding: 24px; }
    .footer { padding: 28px 24px; }
}
@media (max-width: 359px) {
    .nav-content { padding: 0 16px; gap: 8px; }
    .logo img { width: 108px; }
    .btn-back { padding: 0 8px; gap: 4px; }
    .hero-title { font-size: 42px; }
}
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .btn-back, .project-card { transition: none; }
}
