* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
}

html {
    height: 100%;
}

body {
    min-height: 100vh;
    color: #f0f0f2;
    background:
        radial-gradient(circle at 12% 8%, rgba(255, 255, 255, 0.10), transparent 38%),
        radial-gradient(circle at 88% 15%, rgba(190, 190, 200, 0.12), transparent 42%),
        radial-gradient(circle at 25% 80%, rgba(130, 130, 140, 0.14), transparent 48%),
        radial-gradient(circle at 92% 88%, rgba(255, 255, 255, 0.08), transparent 42%),
        radial-gradient(circle at 50% 50%, rgba(90, 90, 100, 0.08), transparent 60%),
        linear-gradient(160deg, #0a0a0c 0%, #18181b 45%, #08080a 100%);
    background-attachment: fixed;
}

/* ---- Liquid glass surface ----
   Every glass element gets: a translucent tinted body, heavy blurred
   backdrop, a bright rim highlight along the top edge (light catching the
   glass), a soft dark rim along the bottom, and a diagonal sheen overlay
   that mimics a curved refractive surface. */
header,
.add-card,
.project-card,
footer {
    position: relative;
    isolation: isolate;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.10), rgba(255, 255, 255, 0.02) 55%, rgba(255, 255, 255, 0.05));
    backdrop-filter: blur(28px) saturate(180%) brightness(1.08);
    -webkit-backdrop-filter: blur(28px) saturate(180%) brightness(1.08);
    border: 1px solid rgba(255, 255, 255, 0.14);
    box-shadow:
        0 12px 40px rgba(0, 0, 0, 0.45),
        0 2px 8px rgba(0, 0, 0, 0.3),
        inset 0 1px 1px rgba(255, 255, 255, 0.45),
        inset 0 -1px 1px rgba(0, 0, 0, 0.25);
    overflow: hidden;
}

header::before,
.add-card::before,
.project-card::before,
footer::before {
    content: '';
    position: absolute;
    inset: 0;
    z-index: -1;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.30) 0%, rgba(255, 255, 255, 0) 35%, rgba(255, 255, 255, 0) 65%, rgba(255, 255, 255, 0.10) 100%);
    mix-blend-mode: overlay;
    pointer-events: none;
}

header {
    padding: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    border-radius: 0 0 28px 28px;
}

.site-info h1 {
    margin-bottom: 0.5rem;
    letter-spacing: -0.02em;
}

.site-info p {
    color: rgba(240, 240, 242, 0.6);
}

/* Artistic wordmark: a bright band swept across the letters on hover,
   like light catching the curve of a piece of glass, plus a slight
   lift/tilt so it feels tactile rather than flat text. */
.signature {
    display: inline-block;
    font-size: 2.25rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    font-style: italic;
    cursor: default;
    background: linear-gradient(
        100deg,
        #ffffff 0%, #ffffff 42%,
        #9a9aa4 48%, #ffffff 54%, #ffffff 58%,
        #9a9aa4 64%,
        #ffffff 70%, #ffffff 100%
    );
    background-size: 260% 100%;
    background-position: 100% 0;
    background-clip: text;
    -webkit-background-clip: text;
    color: transparent;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 1px 16px rgba(255, 255, 255, 0.15);
    transition: background-position 1.1s cubic-bezier(0.2, 0.8, 0.2, 1), transform 0.4s ease;
    transform: perspective(400px) rotateX(0deg);
}

.signature:hover {
    background-position: 0% 0;
    transform: perspective(400px) rotateX(4deg) translateY(-2px);
}

.auth-area {
    display: flex;
    align-items: center;
    gap: 0.85rem;
}

#signedInAs {
    color: rgba(240, 240, 242, 0.7);
    font-size: 0.9rem;
}

#signOutBtn {
    padding: 0.5rem 1.1rem;
    background: rgba(255, 255, 255, 0.07);
    color: rgba(240, 240, 242, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 999px;
    cursor: pointer;
    font-size: 0.875rem;
    box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.25);
    transition: background-color 0.25s, color 0.25s;
}

#signOutBtn:hover {
    background: rgba(255, 255, 255, 0.14);
}

main {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 1rem;
}

.add-card {
    padding: 2rem;
    border-radius: 28px;
    margin-bottom: 2rem;
}

.add-card h2 {
    margin-bottom: 1rem;
    color: #ffffff;
    font-weight: 600;
    letter-spacing: -0.01em;
}

#projectForm {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

#projectForm input {
    flex: 1;
    min-width: 200px;
    padding: 0.85rem 1.25rem;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 999px;
    font-size: 1rem;
    color: #f5f5f7;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.25);
    transition: background-color 0.25s, border-color 0.25s;
}

#projectForm input::placeholder {
    color: rgba(240, 240, 242, 0.4);
}

#projectForm input:focus {
    outline: none;
    background: rgba(255, 255, 255, 0.10);
    border-color: rgba(255, 255, 255, 0.35);
}

#projectForm button {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    padding: 0.85rem 1.75rem;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.28), rgba(255, 255, 255, 0.08));
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 999px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    backdrop-filter: blur(12px);
    box-shadow:
        0 4px 14px rgba(0, 0, 0, 0.35),
        inset 0 1px 1px rgba(255, 255, 255, 0.5),
        inset 0 -1px 1px rgba(0, 0, 0, 0.2);
    transition: background-color 0.25s, transform 0.15s, box-shadow 0.25s;
}

#projectForm button:hover {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.38), rgba(255, 255, 255, 0.12));
    box-shadow:
        0 6px 20px rgba(0, 0, 0, 0.4),
        inset 0 1px 1px rgba(255, 255, 255, 0.6),
        inset 0 -1px 1px rgba(0, 0, 0, 0.2);
}

#projectForm button:active {
    transform: scale(0.96);
}

.projects {
    margin-top: 2rem;
}

.cards-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

.project-card {
    border-radius: 24px;
    transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.35s ease, background-color 0.35s ease;
}

.project-card:hover {
    transform: translateY(-6px) scale(1.01);
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.04) 55%, rgba(255, 255, 255, 0.08));
    box-shadow:
        0 20px 50px rgba(0, 0, 0, 0.5),
        0 4px 12px rgba(0, 0, 0, 0.3),
        inset 0 1px 1px rgba(255, 255, 255, 0.55),
        inset 0 -1px 1px rgba(0, 0, 0, 0.25);
}

.project-preview {
    width: 100%;
    height: 200px;
    border: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    background-color: rgba(0, 0, 0, 0.3);
}

.project-info {
    padding: 1.5rem;
}

.project-info h3 {
    margin-bottom: 0.5rem;
    color: #ffffff;
    font-weight: 600;
}

.project-info a {
    color: rgba(240, 240, 242, 0.65);
    text-decoration: none;
    word-break: break-all;
    transition: color 0.2s;
}

.project-info a:hover {
    color: #ffffff;
    text-decoration: underline;
}

.delete-btn {
    margin-top: 1rem;
    padding: 0.5rem 1.1rem;
    background: rgba(255, 255, 255, 0.07);
    color: rgba(240, 240, 242, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 999px;
    cursor: pointer;
    font-size: 0.875rem;
    box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.2);
    transition: background-color 0.25s, color 0.25s, border-color 0.25s;
}

.delete-btn:hover {
    background: rgba(255, 90, 90, 0.18);
    border-color: rgba(255, 120, 120, 0.35);
    color: #ffb3b3;
}

footer {
    text-align: center;
    padding: 1.5rem;
    margin: 2rem auto 0;
    max-width: 1200px;
    border-radius: 28px 28px 0 0;
    color: rgba(240, 240, 242, 0.5);
}

.footer-uuid {
    margin-top: 0.4rem;
    font-size: 0.75rem;
    color: rgba(240, 240, 242, 0.35);
}
