:root {
    --bg-dark: #0a0a0c;
    --primary: #00f2ff;
    --secondary: #7000ff;
    --text-main: #ffffff;
    --text-muted: #a0a0b0;
    --glass-bg: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);
    --error: #ff4757;
    --gradient: linear-gradient(135deg, var(--primary), var(--secondary));
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    width: 100%;
    overflow-x: hidden;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-main);
    font-family: 'Inter', sans-serif;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* Background Blobs */
.background-blobs {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.15;
    animation: blobMove 20s infinite alternate;
}

.blob-1 {
    width: 500px;
    height: 500px;
    background: var(--primary);
    top: -100px;
    right: -100px;
}

.blob-2 {
    width: 400px;
    height: 400px;
    background: var(--secondary);
    bottom: -100px;
    left: -100px;
}

.blob-3 {
    width: 300px;
    height: 300px;
    background: var(--primary);
    top: 40%;
    left: 30%;
    opacity: 0.1;
}

@keyframes blobMove {
    from { transform: translate(0, 0) scale(1); }
    to { transform: translate(50px, 50px) scale(1.1); }
}

/* Main Container */
.container {
    max-width: 900px;
    width: 92%;
    margin: 40px auto;
}

.hero {
    text-align: center;
    margin-bottom: 40px;
}

.hero h1 {
    font-size: clamp(2rem, 8vw, 4rem);
    font-weight: 800;
    background: var(--gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 15px;
    letter-spacing: -1px;
    line-height: 1.1;
}

.hero .subtitle {
    color: var(--text-muted);
    font-size: clamp(1rem, 4vw, 1.2rem);
    letter-spacing: 0.5px;
    max-width: 600px;
    margin: 0 auto;
}

/* Glassmorphism Card */
.glass {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.3);
}

.generator-card {
    padding: 40px;
    margin-bottom: 40px;
    transition: var(--transition);
}

.generator-card:focus-within {
    border-color: var(--primary);
    box-shadow: 0 0 20px rgba(0, 242, 255, 0.2);
}

.input-group {
    display: flex;
    gap: 15px;
}

#domainInput {
    flex: 1;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 15px 20px;
    color: white;
    font-size: 1.1rem;
    outline: none;
    transition: var(--transition);
}

#domainInput:focus {
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--primary);
}

.btn-primary {
    background: var(--gradient);
    border: none;
    border-radius: 12px;
    padding: 0 30px;
    color: white;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 242, 255, 0.3);
}

.btn-primary:active {
    transform: translateY(0);
}

/* Results Area */
.results-container {
    animation: slideUp 0.6s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(40px); }
    to { opacity: 1; transform: translateY(0); }
}

.result-info {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    margin-bottom: 30px;
    padding: 10px 0;
}

@media (min-width: 600px) {
    .result-info {
        flex-direction: row;
        justify-content: space-between;
    }
}

.badge {
    background: rgba(0, 242, 255, 0.1);
    color: var(--primary);
    padding: 4px 12px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.9rem;
    border: 1px solid rgba(0, 242, 255, 0.2);
}

.expiry-info {
    font-size: 0.9rem;
    color: var(--text-muted);
}

#resExpiry {
    color: white;
    font-weight: 600;
}

.result-cards {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

.result-card {
    padding: 25px;
    border-radius: 18px;
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    gap: 15px;
}

.card-header h3 {
    font-size: 1.1rem;
    color: var(--text-muted);
}

.code-block {
    background: rgba(0, 0, 0, 0.3);
    padding: 15px;
    border-radius: 12px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.9rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.code-block pre {
    white-space: pre-wrap;
    word-break: break-all;
    margin: 0;
    width: 100%;
}

.code-block code {
    white-space: pre-wrap;
    word-break: break-all;
}

pre {
    line-height: 1.5;
}

/* Copy Button */
.copy-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-muted);
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 0.8rem;
    cursor: pointer;
    transition: var(--transition);
}

.copy-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

.copy-btn.copied {
    background: rgba(0, 255, 127, 0.1);
    border-color: #00ff7f;
    color: #00ff7f;
}

/* Utility */
.hidden { display: none !important; }

.error-text {
    color: var(--error);
    margin-top: 15px;
    font-size: 0.9rem;
    text-align: center;
}

/* Loader Spinner */
.loader-spinner {
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    display: none;
}

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

.footer {
    margin-top: auto;
    padding: 40px;
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .container {
        margin: 20px auto;
        width: 100%;
        padding: 0 15px;
    }
    
    .hero {
        margin-bottom: 30px;
    }

    .hero h1 {
        font-size: 2rem;
        word-wrap: break-word;
    }

    .generator-card {
        padding: 25px 15px;
        margin-bottom: 30px;
        border-radius: 16px;
    }

    .input-group {
        flex-direction: column;
        gap: 12px;
    }

    #domainInput {
        width: 100%;
        font-size: 1rem;
        padding: 12px 15px;
    }

    .btn-primary {
        height: 50px;
        width: 100%;
    }

    .result-info {
        flex-direction: column;
        align-items: center;
        gap: 10px;
        text-align: center;
        padding: 0;
    }

    .result-card {
        padding: 20px 15px;
        border-radius: 16px;
    }
    
    .code-block {
        font-size: 0.8rem;
        padding: 12px;
    }

    .card-header {
        flex-direction: column;
        align-items: center;
        gap: 12px;
        margin-bottom: 15px;
        text-align: center;
    }

    .card-header h3 {
        font-size: 1rem;
        width: 100%;
    }

    .copy-btn {
        width: 100%;
        text-align: center;
        padding: 12px;
        font-size: 0.85rem;
    }
}

@media (max-width: 480px) {
    .hero h1 {
        font-size: 1.7rem;
    }
}
