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

:root {
    --primary: #20eca4;
    --primary-soft: rgba(32, 236, 164, 0.1);
    --text-primary: #1a1a1a;
    --text-secondary: #666;
    --text-muted: #999;
    --bg-primary: #ffffff;
    --bg-secondary: #f8f9fa;
    --bg-card: rgba(255, 255, 255, 0.8);
    --border: rgba(0, 0, 0, 0.1);
    --border-light: rgba(0, 0, 0, 0.05);
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
    --shadow-sm: 0 2px 12px rgba(0, 0, 0, 0.04);
}

[data-theme="dark"] {
    --text-primary: #ffffff;
    --text-secondary: #a0a0a0;
    --text-muted: #666;
    --bg-primary: #0a0a0a;
    --bg-secondary: #111;
    --bg-card: rgba(30, 30, 30, 0.6);
    --border: rgba(255, 255, 255, 0.1);
    --border-light: rgba(255, 255, 255, 0.05);
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    --shadow-sm: 0 2px 12px rgba(0, 0, 0, 0.2);
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background: var(--bg-primary);
    min-height: 100vh;
    font-weight: 400;
    transition: all 0.3s ease;
}

.background-gradient {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 0% 0%, rgba(32, 236, 164, 0.03) 0%, transparent 50%),
        radial-gradient(circle at 100% 100%, rgba(32, 236, 164, 0.02) 0%, transparent 50%);
    z-index: -1;
}

/* Theme Toggle */
.theme-toggle-container {
    position: fixed;
    top: 24px;
    right: 24px;
    z-index: 1000;
}

.theme-toggle {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(20px);
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-primary);
    box-shadow: var(--shadow-sm);
}

.theme-toggle:hover {
    border-color: var(--primary);
    transform: scale(1.05);
}

[data-theme="dark"] .theme-toggle .fa-sun,
[data-theme="light"] .theme-toggle .fa-moon {
    display: none;
}

/* Container */
.container {
    max-width: 600px;
    margin: 0 auto;
    padding: 40px 24px;
}

/* Header */
header {
    text-align: center;
    margin-bottom: 60px;
}

.logo {
    font-size: 3rem;
    color: var(--primary);
    margin-bottom: 20px;
    opacity: 0.9;
}

header h1 {
    font-size: 2.5rem;
    font-weight: 600;
    margin-bottom: 12px;
    color: var(--text-primary);
    letter-spacing: -0.02em;
}

.subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
    font-weight: 400;
}

/* Sections */
.section {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 40px;
    margin-bottom: 24px;
    backdrop-filter: blur(20px);
    transition: all 0.3s ease;
    box-shadow: var(--shadow-sm);
    display: flex;
    gap: 24px;
}

.section:hover {
    box-shadow: var(--shadow);
}

.section-icon {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    background: var(--primary-soft);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    font-size: 1.2rem;
}

.section-content {
    flex: 1;
}

.section h2 {
    font-size: 1.4rem;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.section p {
    color: var(--text-secondary);
    margin-bottom: 24px;
    font-size: 0.95rem;
}

/* Buttons */
.btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 16px 24px;
    border-radius: 12px;
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    width: 100%;
    font-family: inherit;
}

.btn-primary {
    background: var(--primary);
    color: #000;
    font-weight: 500;
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 20px rgba(32, 236, 164, 0.3);
}

.btn-secondary {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border);
}

.btn-secondary:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.btn-outline {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border);
}

.btn-outline:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.btn-remove {
    background: transparent;
    color: #ef4444;
    border: 1px solid #ef4444;
    padding: 12px 20px;
    border-radius: 10px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 6px;
    width: auto;
}

.btn-remove:hover {
    background: #ef4444;
    color: white;
    transform: translateY(-1px);
}

/* Wallet Connected */
.wallet-connected {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 24px;
    margin-top: 20px;
}

.wallet-status {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.wallet-status i {
    color: var(--primary);
    font-size: 1.5rem;
}

.wallet-status span {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 1.1rem;
}

.wallet-address {
    font-family: 'Monaco', 'Consolas', monospace;
    font-size: 0.9rem;
    color: var(--text-secondary);
    word-break: break-all;
    margin-bottom: 20px;
    padding: 12px;
    background: var(--bg-primary);
    border-radius: 8px;
    border: 1px solid var(--border-light);
}

/* Instruction Card */
.instruction-card {
    background: var(--bg-secondary);
    border-radius: 16px;
    padding: 24px;
    margin-bottom: 24px;
    border: 1px solid var(--border-light);
}

.instruction-card h4 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 16px;
    color: var(--text-primary);
}

.steps {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.step {
    display: flex;
    align-items: center;
    gap: 12px;
}

.step-number {
    width: 24px;
    height: 24px;
    background: var(--primary);
    color: #000;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 600;
    flex-shrink: 0;
}

.step-text {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.link {
    color: var(--primary);
    text-decoration: none;
}

.link:hover {
    text-decoration: underline;
}

.instruction-card code {
    background: var(--bg-card);
    color: var(--text-primary);
    padding: 4px 8px;
    border-radius: 6px;
    font-family: 'Monaco', 'Consolas', monospace;
    font-size: 0.85rem;
    border: 1px solid var(--border);
}

/* Forms */
.form {
    margin: 24px 0;
}

.input-group {
    position: relative;
    margin-bottom: 16px;
}

.input-group i {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    z-index: 2;
}

.input-group input,
.input-group select {
    width: 100%;
    padding: 16px 16px 16px 48px;
    border: 1px solid var(--border);
    border-radius: 12px;
    font-size: 0.95rem;
    background: var(--bg-primary);
    color: var(--text-primary);
    transition: all 0.3s ease;
    font-family: inherit;
}

.input-group input:focus,
.input-group select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(32, 236, 164, 0.1);
}

/* Domain Cards */
.domain-selection {
    margin-bottom: 32px;
}

.domain-selection h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 16px;
    color: var(--text-primary);
}

.domain-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-light);
    border-radius: 16px;
    padding: 24px;
    margin-bottom: 20px;
}

.domain-header h4 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 16px;
    color: var(--text-primary);
}

.domain-details {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.detail-row {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.domain-name {
    font-size: 1rem;
    color: var(--primary);
    font-weight: 500;
}

.date-input {
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--bg-primary);
    color: var(--text-primary);
    font-family: inherit;
}

.note {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 4px;
}

/* Monitored Domains */
.monitored-section {
    margin-top: 32px;
}

.monitored-section h3 {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 20px;
    color: var(--text-primary);
}

.domains-list {
    min-height: auto;
}

.empty-state-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 60px 40px;
    text-align: center;
    color: var(--text-muted);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-sm);
}

.empty-state-card i {
    font-size: 4rem;
    margin-bottom: 20px;
    opacity: 0.3;
}

.empty-state-card p {
    font-size: 1.2rem;
    margin-bottom: 8px;
    color: var(--text-primary);
    font-weight: 500;
}

.empty-state-card span {
    font-size: 1rem;
    color: var(--text-secondary);
}

/* Domain Items - UPDATED DESIGN */
.domain-item {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 24px;
    margin-bottom: 16px;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-sm);
    position: relative;
}

.domain-item:hover {
    border-color: var(--primary);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.domain-item-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 16px;
    gap: 16px;
}

.domain-info {
    flex: 1;
}

.domain-item-name {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
    word-break: break-all;
}

.domain-item-expiry {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 8px;
}

.domain-item-status {
    font-size: 0.9rem;
    font-weight: 500;
    padding: 4px 8px;
    border-radius: 6px;
    display: inline-block;
}

.domain-item-actions {
    display: flex;
    gap: 12px;
    margin-top: 16px;
}

/* Status colors */
.status-expiring {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.status-warning {
    background: rgba(245, 158, 11, 0.1);
    color: #f59e0b;
    border: 1px solid rgba(245, 158, 11, 0.3);
}

.status-safe {
    background: var(--primary-soft);
    color: var(--primary);
    border: 1px solid rgba(32, 236, 164, 0.3);
}

.status-expired {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.4);
}

/* Loading */
.loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    padding: 40px;
    text-align: center;
    color: var(--text-secondary);
}

.spinner {
    width: 32px;
    height: 32px;
    border: 2px solid var(--border);
    border-top: 2px solid var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Message */
.message {
    padding: 20px;
    border-radius: 12px;
    text-align: center;
    font-weight: 500;
    margin: 20px 0;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        transform: translateY(-10px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.message-success {
    background: var(--primary-soft);
    color: var(--primary);
    border: 1px solid rgba(32, 236, 164, 0.3);
}

.message-error {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

/* Footer */
.app-footer {
    margin-top: 20px;
    padding: 24px 0;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.footer-link {
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
}

.footer-link:hover {
    text-decoration: underline;
}

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

/* Responsive */
@media (max-width: 768px) {
    .container {
        padding: 24px 16px;
    }
    
    header {
        margin-bottom: 40px;
    }
    
    header h1 {
        font-size: 2rem;
    }
    
    .section {
        padding: 32px 24px;
        flex-direction: column;
        gap: 20px;
    }
    
    .section-icon {
        align-self: flex-start;
    }
    
    .theme-toggle {
        width: 44px;
        height: 44px;
    }
    
    .empty-state-card {
        padding: 40px 24px;
    }
    
    .empty-state-card i {
        font-size: 3rem;
    }
    
    .domain-item-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .domain-item-actions {
        width: 100%;
        justify-content: flex-end;
    }
    
    .btn-remove {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 20px 16px;
    }
    
    header h1 {
        font-size: 1.75rem;
    }
    
    .subtitle {
        font-size: 1rem;
    }
    
    .section {
        padding: 24px 20px;
    }
    
    .logo {
        font-size: 2.5rem;
    }
    
    .empty-state-card {
        padding: 32px 20px;
    }
    
    .empty-state-card i {
        font-size: 2.5rem;
    }
    
    .domain-item {
        padding: 20px;
    }
    
    .domain-item-name {
        font-size: 1.1rem;
    }
}
/* Chain Tags */
.chain-tag {
    display: inline-flex;
    align-items: center;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.9em;
    font-weight: 600;
    margin: 0 4px;
    border: 1px solid;
    gap: 6px;
}

.chain-icon {
    width: 16px;
    height: 16px;
    border-radius: 50%;
}

.domain-extension {
    font-size: 0.9em;
    font-weight: 700;
}

.bnb-tag {
    background: rgba(243, 186, 47, 0.15);
    color: #f3ba2f;
    border-color: rgba(243, 186, 47, 0.3);
}

.arb-tag {
    background: rgba(41, 160, 240, 0.15);
    color: #29a0f0;
    border-color: rgba(41, 160, 240, 0.3);
}

/* Modal Styles */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    padding: 20px;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 0;
    width: 100%;
    max-width: 400px;
    box-shadow: var(--shadow);
    backdrop-filter: blur(20px);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px;
    border-bottom: 1px solid var(--border);
}

.modal-header h3 {
    margin: 0;
    color: var(--text-primary);
    font-size: 1.3rem;
    font-weight: 600;
}

.modal-close {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 1rem;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 8px;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.modal-close:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.modal-body {
    padding: 24px;
}

.modal-body p {
    margin: 0 0 20px 0;
    color: var(--text-secondary);
    line-height: 1.5;
    text-align: center;
    font-size: 0.95rem;
}

.g-recaptcha-container {
    display: flex;
    justify-content: center;
    margin: 20px 0;
    padding: 16px;
    background: var(--bg-secondary);
    border-radius: 12px;
    border: 1px solid var(--border-light);
}

.captcha-error {
    display: none;
    align-items: center;
    gap: 8px;
    padding: 12px;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: 8px;
    color: #ef4444;
    font-size: 0.875rem;
    margin: 15px 0;
}

.captcha-error.active {
    display: flex;
}

.captcha-error i {
    font-size: 1rem;
}

.modal-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    margin-top: 20px;
}

.modal-actions .btn {
    min-width: 80px;
    padding: 12px 20px;
    border-radius: 12px;
    font-weight: 500;
}

/* Use your existing button styles */
.modal-actions .btn-primary {
    background: var(--primary);
    color: #000;
    border: none;
}

.modal-actions .btn-primary:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 4px 20px rgba(32, 236, 164, 0.3);
}

.modal-actions .btn-primary:disabled {
    background: var(--text-muted);
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.modal-actions .btn-secondary {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border);
}

.modal-actions .btn-secondary:hover {
    border-color: var(--primary);
    color: var(--primary);
}

/* Responsive */
@media (max-width: 480px) {
    .modal {
        padding: 16px;
    }
    
    .modal-content {
        max-width: none;
    }
    
    .modal-header {
        padding: 20px;
    }
    
    .modal-body {
        padding: 20px;
    }
    
    .g-recaptcha {
        transform: scale(0.85);
    }
    
    .modal-actions {
        flex-direction: column;
    }
    
    .modal-actions .btn {
        width: 100%;
    }
}