/* CSS Variables for theming */
:root {
    /* Light theme */
    --bg-primary: #ffffff;
    --bg-secondary: #f8fafc;
    --bg-tertiary: #f1f5f9;
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --text-muted: #94a3b8;
    --border-color: #e2e8f0;
    --border-hover: #cbd5e1;
    --accent-primary: #3b82f6;
    --accent-secondary: #1d4ed8;
    --accent-success: #10b981;
    --accent-warning: #f59e0b;
    --accent-error: #ef4444;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
}

[data-theme="dark"] {
    /* Dark theme */
    --bg-primary: #0f172a;
    --bg-secondary: #1e293b;
    --bg-tertiary: #334155;
    --text-primary: #f1f5f9;
    --text-secondary: #cbd5e1;
    --text-muted: #64748b;
    --border-color: #334155;
    --border-hover: #475569;
    --accent-primary: #60a5fa;
    --accent-secondary: #3b82f6;
    --accent-success: #34d399;
    --accent-warning: #fbbf24;
    --accent-error: #f87171;
}

/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
.header {
    background: linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-secondary) 100%);
    color: white;
    padding: 2rem 0;
    margin-bottom: 2rem;
    border-radius: 0 0 20px 20px;
    box-shadow: var(--shadow-lg);
}

.header-content {
    text-align: center;
}

.logo {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
}

.logo i {
    font-size: 3rem;
    color: #fbbf24;
}

.subtitle {
    font-size: 1.1rem;
    opacity: 0.9;
    font-weight: 300;
}

/* Theme toggle */
.theme-toggle {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    padding: 0.5rem;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.theme-toggle:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}

/* Main content */
.main-content {
    background: var(--bg-secondary);
    border-radius: 20px;
    box-shadow: var(--shadow-xl);
    overflow: hidden;
    margin-bottom: 2rem;
}

/* Search section */
.search-section {
    padding: 3rem 2rem;
    text-align: center;
    background: var(--bg-tertiary);
}

.search-container {
    max-width: 600px;
    margin: 0 auto;
}

.search-form {
    width: 100%;
}

.input-group {
    display: flex;
    background: var(--bg-primary);
    border-radius: 50px;
    box-shadow: var(--shadow-lg);
    overflow: hidden;
    border: 2px solid var(--border-color);
    transition: all 0.3s ease;
}

.input-group:focus-within {
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.input-group input {
    flex: 1;
    padding: 1.25rem 1.5rem;
    border: none;
    font-size: 1rem;
    outline: none;
    background: transparent;
    color: var(--text-primary);
}

.input-group input::placeholder {
    color: var(--text-muted);
}

.search-btn {
    background: linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-secondary) 100%);
    color: white;
    border: none;
    padding: 1.25rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.search-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

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

.search-btn i {
    font-size: 1.1rem;
}

/* Button group */
.button-group {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
}

.btn {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 10px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
}

.btn-primary {
    background: var(--accent-primary);
    color: white;
}

.btn-primary:hover {
    background: var(--accent-secondary);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-secondary {
    background: var(--bg-primary);
    color: var(--text-primary);
    border: 2px solid var(--border-color);
}

.btn-secondary:hover {
    border-color: var(--accent-primary);
    color: var(--accent-primary);
    transform: translateY(-2px);
}

.btn-reset {
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    border: 2px solid var(--border-color);
}

.btn-reset:hover {
    background: var(--accent-error);
    color: white;
    border-color: var(--accent-error);
}

/* Loading */
.loading {
    text-align: center;
    padding: 3rem 2rem;
    background: var(--bg-primary);
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid var(--border-color);
    border-top: 4px solid var(--accent-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1rem;
}

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

.loading p {
    color: var(--text-secondary);
    font-size: 1rem;
}

/* Error message */
.error-message {
    background: linear-gradient(135deg, #fef2f2 0%, #fee2e2 100%);
    color: var(--accent-error);
    padding: 1rem 1.5rem;
    margin: 1rem 2rem;
    border-radius: 10px;
    border-left: 4px solid var(--accent-error);
    display: flex;
    align-items: center;
    gap: 0.75rem;
    box-shadow: var(--shadow-sm);
}

[data-theme="dark"] .error-message {
    background: linear-gradient(135deg, #450a0a 0%, #7f1d1d 100%);
}

.error-message i {
    font-size: 1.2rem;
}

/* Results section */
.results-section {
    padding: 2rem;
    background: var(--bg-primary);
}

.results-header {
    text-align: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--border-color);
}

.results-header h2 {
    font-size: 1.8rem;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.domain-name {
    color: var(--accent-primary);
    font-weight: 700;
    font-size: 1.2rem;
}

/* Status card */
.status-card {
    background: var(--bg-secondary);
    border-radius: 15px;
    padding: 1.5rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow-md);
    display: flex;
    align-items: center;
    gap: 1.5rem;
    border-left: 5px solid;
    transition: all 0.3s ease;
}

.status-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.status-card.active {
    border-left-color: var(--accent-success);
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.1) 0%, rgba(16, 185, 129, 0.05) 100%);
}

.status-card.inactive {
    border-left-color: var(--accent-error);
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.1) 0%, rgba(239, 68, 68, 0.05) 100%);
}

.status-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.status-card.active .status-icon {
    background: var(--accent-success);
    color: white;
}

.status-card.inactive .status-icon {
    background: var(--accent-error);
    color: white;
}

.status-info h3 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.status-text {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.status-card.active .status-text {
    color: var(--accent-success);
}

.status-card.inactive .status-text {
    color: var(--accent-error);
}

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

/* Date cards */
.date-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.date-card {
    background: var(--bg-secondary);
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: var(--shadow-md);
    display: flex;
    align-items: center;
    gap: 1rem;
    transition: all 0.3s ease;
    border-left: 4px solid var(--border-color);
}

.date-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.date-card.normal {
    border-left-color: var(--accent-primary);
}

.date-card.warning {
    border-left-color: var(--accent-warning);
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.1) 0%, rgba(245, 158, 11, 0.05) 100%);
}

.date-card.urgent {
    border-left-color: var(--accent-error);
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.1) 0%, rgba(239, 68, 68, 0.05) 100%);
}

.date-icon {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: var(--accent-primary);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.date-card.warning .date-icon {
    background: var(--accent-warning);
}

.date-card.urgent .date-icon {
    background: var(--accent-error);
}

.date-info h3 {
    font-size: 1rem;
    margin-bottom: 0.25rem;
    color: var(--text-primary);
}

.date-info p {
    font-size: 0.9rem;
    color: var(--text-primary);
    font-weight: 500;
}

.date-info small {
    font-size: 0.8rem;
    color: var(--text-secondary);
    display: block;
    margin-top: 0.25rem;
}

/* DNS section */
.dns-section {
    margin-bottom: 2rem;
}

.dns-section h3 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.dns-section h3 i {
    color: var(--accent-primary);
}

.dns-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1rem;
}

.dns-card {
    background: var(--bg-secondary);
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: var(--shadow-md);
    transition: all 0.3s ease;
}

.dns-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.dns-card h4 {
    font-size: 1.1rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--border-color);
}

.dns-card h4 i {
    font-size: 1.2rem;
}

.dns-card ul {
    list-style: none;
}

.dns-card li {
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-secondary);
    font-family: 'Monaco', 'Menlo', monospace;
    font-size: 0.9rem;
}

.dns-card li:last-child {
    border-bottom: none;
}

/* Registrant info */
.registrant-info {
    background: var(--bg-secondary);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow-md);
}

.registrant-info h3 {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.registrant-info h3 i {
    color: var(--accent-primary);
}

.registrant-info p {
    color: var(--text-secondary);
    line-height: 1.6;
}

/* WHOIS raw */
.whois-raw {
    background: var(--bg-secondary);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow-md);
}

.whois-raw h3 {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.whois-raw h3 i {
    color: var(--accent-primary);
}

.whois-content {
    background: var(--bg-tertiary);
    border-radius: 8px;
    padding: 1rem;
    max-height: 400px;
    overflow-y: auto;
}

.whois-content pre {
    color: var(--text-secondary);
    font-family: 'Monaco', 'Menlo', monospace;
    font-size: 0.85rem;
    line-height: 1.5;
    white-space: pre-wrap;
    word-wrap: break-word;
}

/* Examples section */
.examples-section {
    background: var(--bg-secondary);
    border-radius: 12px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow-md);
}

.examples-section h3 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
    text-align: center;
}

.example-domains {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    justify-content: center;
}

.example-domain {
    background: var(--bg-primary);
    color: var(--accent-primary);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid var(--border-color);
    font-size: 0.9rem;
    font-weight: 500;
}

.example-domain:hover {
    background: var(--accent-primary);
    color: white;
    border-color: var(--accent-primary);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

/* Rate limit status */
.rate-limit-status {
    background: var(--bg-secondary);
    border-radius: 10px;
    padding: 1rem 1.5rem;
    margin: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: var(--shadow-sm);
    border-left: 4px solid var(--accent-primary);
}

.status-text {
    color: var(--text-primary);
    font-weight: 500;
}

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

/* Footer */
.footer {
    background: var(--bg-secondary);
    padding: 2rem 0;
    margin-top: 3rem;
    border-radius: 20px 20px 0 0;
    box-shadow: var(--shadow-lg);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-content p {
    color: var(--text-secondary);
}

.footer-links {
    display: flex;
    gap: 1.5rem;
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--accent-primary);
}

/* Responsive design */
@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }
    
    .header {
        padding: 1.5rem 0;
        margin-bottom: 1.5rem;
    }
    
    .logo {
        font-size: 2rem;
    }
    
    .logo i {
        font-size: 2.5rem;
    }
    
    .search-section {
        padding: 2rem 1rem;
    }
    
    .input-group {
        flex-direction: column;
        border-radius: 15px;
    }
    
    .input-group input {
        padding: 1rem 1.5rem;
    }
    
    .search-btn {
        padding: 1rem 1.5rem;
        border-radius: 0 0 15px 15px;
    }
    
    .button-group {
        flex-direction: column;
        align-items: center;
    }
    
    .btn {
        width: 100%;
        max-width: 200px;
        justify-content: center;
    }
    
    .results-section {
        padding: 1.5rem;
    }
    
    .date-cards {
        grid-template-columns: 1fr;
    }
    
    .dns-grid {
        grid-template-columns: 1fr;
    }
    
    .status-card {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }
    
    .rate-limit-status {
        flex-direction: column;
        gap: 0.5rem;
        text-align: center;
    }
    
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .logo {
        font-size: 1.5rem;
    }
    
    .logo i {
        font-size: 2rem;
    }
    
    .subtitle {
        font-size: 1rem;
    }
    
    .search-section {
        padding: 1.5rem 1rem;
    }
    
    .results-section {
        padding: 1rem;
    }
    
    .date-cards {
        gap: 0.75rem;
    }
    
    .date-card {
        padding: 1rem;
    }
    
    .dns-card {
        padding: 1rem;
    }
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.5s ease-out;
}

/* Scrollbar styling */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-tertiary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--border-hover);
} 