body {
    margin: 0;
    /* Apple-style typography */
    font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    /* Dot Grid Pattern + Soft Gradients */
    background-color: #f8fafc;
    background-image: 
        radial-gradient(at 0% 0%, rgba(16, 185, 129, 0.12) 0px, transparent 40%),
        radial-gradient(at 100% 100%, rgba(52, 211, 153, 0.1) 0px, transparent 40%),
        radial-gradient(rgba(15, 23, 42, 0.04) 1px, transparent 1px);
    background-size: 100% 100%, 100% 100%, 24px 24px;
    color: #334155;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
}

/* Decorative Background Elements */
.bg-shape {
    position: fixed;
    border-radius: 50%;
    filter: blur(90px);
    z-index: -1;
    opacity: 0.3;
    animation: float 15s infinite alternate ease-in-out;
}

.shape-1 {
    width: 400px;
    height: 400px;
    background: #34d399;
    top: -50px;
    left: -50px;
}

.shape-2 {
    width: 500px;
    height: 500px;
    background: #6ee7b7;
    bottom: -100px;
    right: -100px;
    animation-duration: 20s;
}

@keyframes float {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(20px, 30px) scale(1.05); }
}

/* Main Cards */
.card, .box {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(24px); 
    -webkit-backdrop-filter: blur(24px);
    padding: 48px 40px;
    border-radius: 24px; 
    width: 100%;
    max-width: 340px;
    box-shadow: 
        0 4px 6px -1px rgba(0, 0, 0, 0.02),
        0 10px 15px -3px rgba(0, 0, 0, 0.03),
        0 25px 50px -12px rgba(16, 185, 129, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.9);
    text-align: center;
    box-sizing: border-box;
    position: relative;
}

.card.wide {
    max-width: 600px;
}

h1, h2 {
    color: #0f172a;
    margin-top: 0;
    margin-bottom: 24px;
    font-weight: 600;
    letter-spacing: -0.04em;
    font-size: 26px;
}

p {
    color: #64748b;
    font-size: 14px;
    margin-bottom: 20px;
    line-height: 1.5;
}

input {
    width: 100%;
    padding: 14px 16px;
    margin: 8px 0 16px 0;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    background: #ffffff;
    color: #0f172a;
    outline: none;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    box-sizing: border-box;
    font-size: 15px;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.02);
}

input::placeholder {
    color: #94a3b8;
}

input:focus {
    border-color: #10b981;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.01), 0 0 0 4px rgba(16, 185, 129, 0.15);
    transform: translateY(-1px);
}

button, .btn {
    display: block;
    width: 100%;
    padding: 14px;
    margin-top: 12px;
    background: linear-gradient(180deg, #10b981 0%, #059669 100%);
    border: 1px solid #047857;
    border-radius: 12px;
    color: white;
    cursor: pointer;
    font-weight: 500;
    font-size: 16px;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    text-decoration: none;
    box-sizing: border-box;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25), 0 4px 6px -1px rgba(16, 185, 129, 0.2);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

button:hover, .btn:hover {
    transform: translateY(-1px);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3), 0 10px 15px -3px rgba(16, 185, 129, 0.25), 0 4px 6px -2px rgba(16, 185, 129, 0.1);
}

button:active, .btn:active {
    transform: translateY(0) scale(0.98); 
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1), 0 2px 4px rgba(16, 185, 129, 0.15);
}

.btn-secondary {
    background: transparent;
    border: 1px solid #e2e8f0;
    color: #475569;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
    text-shadow: none;
}

.btn-secondary:hover {
    background: #f8fafc;
    color: #0f172a;
    box-shadow: 0 4px 6px -1px rgba(0,0,0,0.05);
}

a.link {
    color: #64748b;
    display: inline-block;
    margin-top: 24px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: color 0.2s ease;
}

a.link:hover {
    color: #10b981;
}

.error {
    background: #fef2f2;
    color: #dc2626;
    padding: 14px;
    border-radius: 12px;
    margin-top: 20px;
    font-size: 14px;
    font-weight: 500;
    border: 1px solid rgba(220, 38, 38, 0.2);
    animation: shake 0.4s ease-in-out;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-4px); }
    75% { transform: translateX(4px); }
}

/* Obsidian AI Feature Styles */
.result-box {
    margin-top: 20px;
    padding: 16px;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 12px;
    text-align: left;
    font-size: 14px;
    line-height: 1.6;
    max-height: 300px;
    overflow-y: auto;
    border: 1px solid rgba(0,0,0,0.05);
    display: none;
    color: #334155;
}

.btn-obsidian {
    background: linear-gradient(180deg, #8b5cf6 0%, #7c3aed 100%);
    border: 1px solid #6d28d9;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25), 0 4px 6px -1px rgba(124, 58, 237, 0.2);
    display: none;
}

.btn-obsidian:hover {
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3), 0 10px 15px -3px rgba(124, 58, 237, 0.25);
}
