/* Background image */
body {
    background-image: url('../bg.svg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
}

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

@keyframes fadeInScale {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

@keyframes pulse {
    0% { opacity: 0.6; }
    50% { opacity: 1; }
    100% { opacity: 0.6; }
}

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

.fade-in-scale {
    animation: fadeInScale 0.4s ease-out forwards;
}

.result-container {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s ease-out;
}

.result-container.show {
    opacity: 1;
    transform: translateY(0);
}

.loading-indicator {
    animation: pulse 1.5s infinite;
}

/* Tab content transition */
.tab-content {
    display: block !important;
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
}

.tab-content.active {
    opacity: 1;
}

/* Neo-brutalism styles */
.neo-brutal {
    border: 3px solid #000;
    box-shadow: 8px 8px 0px 0px rgba(0,0,0,1);
    transition: all 0.2s ease;
    background-color: rgba(255, 255, 255, 0.95);
}

.neo-brutal-sm {
    border: 2px solid #000;
    box-shadow: 4px 4px 0px 0px rgba(0,0,0,1);
    transition: all 0.2s ease;
    background-color: rgba(255, 255, 255, 0.95);
}

.neo-brutal:hover, .neo-brutal-sm:hover {
    transform: translate(-2px, -2px);
    box-shadow: 10px 10px 0px 0px rgba(0,0,0,1);
}

.neo-input {
    border: 2px solid #000 !important;
    border-radius: 0 !important;
    background-color: #fff !important;
}

.neo-btn {
    border: 2px solid #000 !important;
    border-radius: 0 !important;
    box-shadow: 4px 4px 0px 0px rgba(0,0,0,1);
    transition: all 0.2s ease;
}

.neo-btn:hover {
    transform: translate(-2px, -2px);
    box-shadow: 6px 6px 0px 0px rgba(0,0,0,1);
}

.neo-card {
    border: 3px solid #000;
    border-radius: 0 !important;
    box-shadow: 8px 8px 0px 0px rgba(0,0,0,1);
    background-color: rgba(255, 255, 255, 0.95);
}

.neo-stats {
    border: 2px solid #000;
    border-radius: 0 !important;
    background-color: rgba(255, 255, 255, 0.95);
}

.neo-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1rem;
    border: 2px solid #000;
    background-color: rgba(255, 255, 255, 0.95);
}

.neo-table th {
    background-color: #f0f0f0;
    font-weight: bold;
    text-align: left;
    padding: 0.75rem;
    border: 1px solid #000;
}

.neo-table td {
    padding: 0.75rem;
    border: 1px solid #000;
}

.neo-table tr:nth-child(even) {
    background-color: #f9f9f9;
}

[data-theme="dark"] .neo-table {
    background-color: var(--card-bg);
    border-color: var(--table-border);
}

[data-theme="dark"] .neo-table th {
    background-color: var(--table-header-bg);
    color: var(--text-color);
    border-color: var(--table-border);
}

[data-theme="dark"] .neo-table td {
    border-color: var(--table-border);
    color: var(--text-color);
}

[data-theme="dark"] .neo-table tr:nth-child(even) {
    background-color: var(--table-row-alt-bg);
}

[data-theme="dark"] .neo-table tr:nth-child(odd) {
    background-color: var(--table-row-bg);
}

/* Fix for bg-[#e3f2fd] tables in dark mode */
.p-2.bg-\[\#e3f2fd\] {
    background-color: rgba(227, 242, 253, 0.9);
}

[data-theme="dark"] .p-2.bg-\[\#e3f2fd\] {
    background-color: rgba(38, 50, 56, 0.7);
    color: #e3f2fd;
}

[data-theme="dark"] .p-2.bg-\[\#fff3e0\] {
    background-color: rgba(50, 38, 32, 0.7);
    color: #fff3e0;
}

[data-theme="dark"] .p-2.bg-\[\#e8f5e9\] {
    background-color: rgba(38, 54, 40, 0.7);
    color: #e8f5e9;
}

[data-theme="dark"] .p-2.bg-\[\#fff8e1\] {
    background-color: rgba(54, 52, 38, 0.7);
    color: #fff8e1;
}

[data-theme="dark"] .p-2.bg-\[\#ffebee\] {
    background-color: rgba(54, 38, 40, 0.7);
    color: #ffebee;
}

/* Fix for Nameservers and Subject Alternative Names sections */
.p-2.bg-\[\#f3e5f5\] {
    background-color: rgba(243, 229, 245, 0.9);
}

[data-theme="dark"] .p-2.bg-\[\#f3e5f5\] {
    background-color: rgba(48, 34, 50, 0.7);
    color: #f3e5f5;
}

[data-theme="dark"] .p-2.bg-\[\#ffcece\],
[data-theme="dark"] .p-2.bg-\[\#d6ffdf\],
[data-theme="dark"] .p-2.bg-\[\#d6f3ff\],
[data-theme="dark"] .p-2.bg-\[\#f1d6ff\],
[data-theme="dark"] .p-2.bg-\[\#fff2d6\],
[data-theme="dark"] .p-2.bg-\[\#ffd6ec\],
[data-theme="dark"] .p-2.bg-\[\#d6fff2\] {
    background-color: rgba(40, 40, 45, 0.7);
    color: #f0f0f0;
}

.tld-chip {
    display: inline-block;
    padding: 8px 16px;
    margin: 5px;
    background-color: #ffde59;
    border: 2px solid #000;
    box-shadow: 3px 3px 0px 0px rgba(0,0,0,1);
    cursor: pointer;
    transition: all 0.2s ease;
}

.tld-chip:hover {
    transform: translate(-2px, -2px);
    box-shadow: 5px 5px 0px 0px rgba(0,0,0,1);
}

.tld-chip.active {
    background-color: #ff5757;
    color: white;
}

/* Tab button styles */
.tab-btn {
    display: inline-block;
    padding: 10px 20px;
    margin: 0 5px;
    border: 2px solid #000;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s ease;
}

.tab-btn:hover {
    transform: translate(-2px, -2px);
    box-shadow: 4px 4px 0px 0px rgba(0,0,0,1);
}

.tab-btn.active {
    color: white;
    box-shadow: 4px 4px 0px 0px rgba(0,0,0,1);
}

/* Tool-specific tab colors - Light Mode */
.tab-btn[href*="whois-checker"] {
    background-color: #ffd6a5;
}
.tab-btn[href*="dns-checker"] {
    background-color: #a0c4ff;
}
.tab-btn[href*="ssl-checker"] {
    background-color: #bdb2ff;
}
.tab-btn[href*="ip-lookup"] {
    background-color: #caffbf;
}
.tab-btn[href*="blacklist-checker"] {
    background-color: #ffadad;
}
.tab-btn[href*="http-status-checker"] {
    background-color: #9bf6ff;
}
.tab-btn[href*="down-or-not"] {
    background-color: #fdffb6;
}
.tab-btn[href*="tld-grace-period"] {
    background-color: #ffc6ff;
}

/* Active tab styles */
.tab-btn[href*="whois-checker"].active {
    background-color: #ff9e44;
}
.tab-btn[href*="dns-checker"].active {
    background-color: #4d94ff;
}
.tab-btn[href*="ssl-checker"].active {
    background-color: #9181ff;
}
.tab-btn[href*="ip-lookup"].active {
    background-color: #76e766;
}
.tab-btn[href*="blacklist-checker"].active {
    background-color: #ff5757;
}
.tab-btn[href*="http-status-checker"].active {
    background-color: #00d7e6;
}
.tab-btn[href*="down-or-not"].active {
    background-color: #f0f055;
}
.tab-btn[href*="tld-grace-period"].active {
    background-color: #ff66ff;
}

/* Tool-specific tab colors - Dark Mode */
[data-theme="dark"] .tab-btn[href*="whois-checker"] {
    background-color: #b37d4e;
    color: #f0f0f0;
}
[data-theme="dark"] .tab-btn[href*="dns-checker"] {
    background-color: #4a6b9f;
    color: #f0f0f0;
}
[data-theme="dark"] .tab-btn[href*="ssl-checker"] {
    background-color: #6c5fa3;
    color: #f0f0f0;
}
[data-theme="dark"] .tab-btn[href*="ip-lookup"] {
    background-color: #5a9c52;
    color: #f0f0f0;
}
[data-theme="dark"] .tab-btn[href*="blacklist-checker"] {
    background-color: #a34a4a;
    color: #f0f0f0;
}
[data-theme="dark"] .tab-btn[href*="http-status-checker"] {
    background-color: #4a8f99;
    color: #f0f0f0;
}
[data-theme="dark"] .tab-btn[href*="down-or-not"] {
    background-color: #a3a34a;
    color: #f0f0f0;
}
[data-theme="dark"] .tab-btn[href*="tld-grace-period"] {
    background-color: #9c4a9c;
    color: #f0f0f0;
}

/* Active tab styles in dark mode */
[data-theme="dark"] .tab-btn[href*="whois-checker"].active {
    background-color: #ff9e44;
    color: white;
}
[data-theme="dark"] .tab-btn[href*="dns-checker"].active {
    background-color: #4d94ff;
    color: white;
}
[data-theme="dark"] .tab-btn[href*="ssl-checker"].active {
    background-color: #9181ff;
    color: white;
}
[data-theme="dark"] .tab-btn[href*="ip-lookup"].active {
    background-color: #76e766;
    color: black;
}
[data-theme="dark"] .tab-btn[href*="blacklist-checker"].active {
    background-color: #ff5757;
    color: white;
}
[data-theme="dark"] .tab-btn[href*="http-status-checker"].active {
    background-color: #00d7e6;
    color: black;
}
[data-theme="dark"] .tab-btn[href*="down-or-not"].active {
    background-color: #f0f055;
    color: black;
}
[data-theme="dark"] .tab-btn[href*="tld-grace-period"].active {
    background-color: #ff66ff;
    color: black;
}

[data-theme="dark"] .tab-btn {
    border-color: var(--border-color);
}

/* Go to Top button styles */
#goToTopBtn {
    display: none;
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 99;
    border: 3px solid #000;
    background-color: #ff5757;
    color: white;
    cursor: pointer;
    width: 50px;
    height: 50px;
    border-radius: 0;
    font-size: 24px;
    box-shadow: 4px 4px 0px 0px rgba(0,0,0,1);
    transition: all 0.3s ease;
    opacity: 0;
}

#goToTopBtn:hover {
    transform: translate(-2px, -2px);
    box-shadow: 6px 6px 0px 0px rgba(0,0,0,1);
}

/* Mobile adjustments for Go to Top button */
@media (max-width: 768px) {
    #goToTopBtn {
        bottom: 20px;
        right: 20px;
        width: 40px;
        height: 40px;
        font-size: 20px;
    }
}

/* Dark mode styles for Go to Top button */
[data-theme="dark"] #goToTopBtn {
    background-color: #ff5757;
    border-color: #fff;
    box-shadow: 4px 4px 0px 0px rgba(255,255,255,0.8);
}

[data-theme="dark"] #goToTopBtn:hover {
    box-shadow: 6px 6px 0px 0px rgba(255,255,255,0.8);
}

/* Dark mode styles */
[data-theme="dark"] {
    --bg-color: #1a1a1a;
    --text-color: #f0f0f0;
    --card-bg: #2a2a2a;
    --input-bg: #333333;
    --border-color: #444444;
    --link-color: #61dafb;
    --muted-text: #aaaaaa;
    --highlight-bg: #3a3a3a;
    --table-header-bg: #3a3a3a;
    --table-row-bg: #2a2a2a;
    --table-row-alt-bg: #333333;
    --table-border: #555555;
}

[data-theme="dark"] body {
    background-color: var(--bg-color);
    color: var(--text-color);
}

[data-theme="dark"] .neo-brutal,
[data-theme="dark"] .neo-brutal-sm,
[data-theme="dark"] .neo-card {
    background-color: var(--card-bg) !important;
    border-color: var(--border-color);
    color: var(--text-color);
}

[data-theme="dark"] .neo-input {
    background-color: var(--input-bg) !important;
    border-color: var(--border-color) !important;
    color: var(--text-color);
}

[data-theme="dark"] .tab-btn {
    background-color: var(--card-bg);
    color: var(--text-color);
    border-color: var(--border-color);
}

[data-theme="dark"] .tab-btn.active {
    background-color: #ff5757;
    color: white;
}

[data-theme="dark"] a {
    color: var(--link-color);
}

[data-theme="dark"] .label-text {
    color: var(--text-color) !important;
}

[data-theme="dark"] .collapse-title {
    color: var(--text-color);
}

[data-theme="dark"] .collapse-content {
    background-color: var(--highlight-bg);
    color: var(--text-color);
}

[data-theme="dark"] table th,
[data-theme="dark"] table td {
    color: var(--text-color);
    border-color: var(--border-color);
}

[data-theme="dark"] .neo-stats,
[data-theme="dark"] .neo-stats-sm {
    background-color: var(--highlight-bg) !important;
    color: var(--text-color);
}

[data-theme="dark"] .text-sm,
[data-theme="dark"] .text-xs {
    color: var(--muted-text);
}

[data-theme="dark"] .nav-link {
    background-color: var(--card-bg);
    color: var(--text-color);
    border-color: var(--border-color);
}

[data-theme="dark"] .nav-link.active {
    background-color: #ff5757;
    color: white;
}

/* Language toggle styles */
.language-toggle {
    cursor: pointer;
    padding: 8px 12px;
    border: 2px solid #000;
    background-color: white;
    transition: all 0.2s ease;
    box-shadow: 3px 3px 0px 0px rgba(0,0,0,1);
    display: flex;
    align-items: center;
    gap: 6px;
}

.language-toggle:hover {
    transform: translate(-2px, -2px);
    box-shadow: 5px 5px 0px 0px rgba(0,0,0,1);
}

[data-theme="dark"] .language-toggle {
    background-color: #333;
    color: white;
    border-color: #555;
}

/* Theme toggle button */
.theme-toggle {
    cursor: pointer;
    padding: 8px 12px;
    border: 2px solid #000;
    background-color: white;
    transition: all 0.2s ease;
    box-shadow: 3px 3px 0px 0px rgba(0,0,0,1);
}

.theme-toggle:hover {
    transform: translate(-2px, -2px);
    box-shadow: 5px 5px 0px 0px rgba(0,0,0,1);
}

[data-theme="dark"] .theme-toggle {
    background-color: #333;
    color: white;
    border-color: #555;
}

/* Neo button small styles */
.neo-btn-sm {
    border: 1px solid #000 !important;
    border-radius: 0 !important;
    box-shadow: 2px 2px 0px 0px rgba(0,0,0,1);
    transition: all 0.2s ease;
}

.neo-btn-sm:hover {
    transform: translate(-1px, -1px);
    box-shadow: 3px 3px 0px 0px rgba(0,0,0,1);
}

/* Header navigation styles */
.nav-link {
    display: inline-block;
    padding: 8px 16px;
    margin: 0 5px;
    background-color: rgba(255, 255, 255, 0.9);
    border: 2px solid #000;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s ease;
}

.nav-link:hover {
    transform: translate(-2px, -2px);
    box-shadow: 4px 4px 0px 0px rgba(0,0,0,1);
}

.nav-link.active {
    background-color: #ff5757;
    color: white;
    box-shadow: 4px 4px 0px 0px rgba(0,0,0,1);
}

[data-theme="dark"] .tab-btn {
    border-color: var(--border-color);
}

/* Tab content styles */
#tabContent {
    background-color: rgba(255, 255, 255, 0.95);
    border: 2px solid #000;
    padding: 20px;
    margin-top: 10px;
    box-shadow: 6px 6px 0px 0px rgba(0,0,0,1);
}

[data-theme="dark"] #tabContent {
    background-color: var(--card-bg);
    border-color: var(--border-color);
    color: var(--text-color);
}

/* Domain favicon styles */
.domain-title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 1rem;
}

.domain-favicon {
    width: 24px;
    height: 24px;
    object-fit: contain;
}

/* Ensure all tables have consistent styling */
table.neo-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1rem;
}

table.neo-table th,
table.neo-table td {
    padding: 0.75rem;
}

/* Ensure code blocks and pre elements are readable in dark mode */
[data-theme="dark"] pre,
[data-theme="dark"] code {
    background-color: #2d2d2d;
    color: #f0f0f0;
    border-color: var(--border-color);
}

/* Ensure form inputs and selects are readable in dark mode */
[data-theme="dark"] select option {
    background-color: var(--input-bg);
    color: var(--text-color);
}

[data-theme="dark"] input::placeholder {
    color: var(--muted-text);
}

/* Mobile optimizations for forms and results */
@media (max-width: 768px) {
    /* Reduce body padding on mobile */
    body {
        padding: 0.5rem;
    }
    
    /* Simplify borders on mobile - remove nested border effects */
    .neo-brutal {
        border: 2px solid #000;
        box-shadow: 3px 3px 0px 0px rgba(0,0,0,1);
        margin-bottom: 0.75rem;
    }
    
    .neo-brutal-sm {
        border: 1px solid #000;
        box-shadow: 2px 2px 0px 0px rgba(0,0,0,1);
        margin-bottom: 0.5rem;
        padding: 0.75rem;
    }
    
    /* Remove hover effects on mobile for better performance */
    .neo-brutal:hover, 
    .neo-brutal-sm:hover {
        transform: none;
        box-shadow: 3px 3px 0px 0px rgba(0,0,0,1);
    }
    
    .neo-brutal-sm:hover {
        box-shadow: 2px 2px 0px 0px rgba(0,0,0,1);
    }
    
    /* Main content container adjustments */
    .container {
        padding-left: 0.5rem;
        padding-right: 0.5rem;
    }
    
    /* Tool content spacing */
    #tabContent {
        border: 1px solid #000;
        padding: 1rem;
        margin-top: 0.5rem;
        box-shadow: 2px 2px 0px 0px rgba(0,0,0,1);
    }
    
    /* Form elements optimization */
    .neo-input,
    .neo-btn {
        font-size: 16px; /* Prevent zoom on iOS */
        padding: 0.75rem;
        border: 1px solid #000 !important;
        box-shadow: 2px 2px 0px 0px rgba(0,0,0,1);
    }
    
    .neo-btn:hover {
        transform: none;
        box-shadow: 2px 2px 0px 0px rgba(0,0,0,1);
    }
    
    /* Result containers spacing */
    .result-container {
        margin-top: 1rem;
    }
    
    .result-container > div {
        margin-bottom: 0.75rem;
    }
    
    /* Improve tap targets */
    .tab-btn {
        padding: 1rem;
        min-height: 3.5rem;
        border: 1px solid #000;
        box-shadow: 2px 2px 0px 0px rgba(0,0,0,1);
    }
    
    .tab-btn:hover {
        transform: none;
        box-shadow: 2px 2px 0px 0px rgba(0,0,0,1);
    }
    
    /* Grid adjustments for mobile */
    .grid-cols-1.sm\:grid-cols-2.lg\:grid-cols-4 {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.5rem;
    }
    
    /* Text size adjustments */
    .text-4xl {
        font-size: 1.875rem;
    }
    
    .text-2xl {
        font-size: 1.5rem;
    }
    
    /* Header adjustments */
    header .neo-brutal {
        padding: 0.75rem;
        margin-bottom: 0.75rem;
    }
    
    /* Navigation improvements */
    .nav-link {
        padding: 0.5rem 0.75rem;
        font-size: 0.875rem;
        border: 1px solid #000;
        box-shadow: 2px 2px 0px 0px rgba(0,0,0,1);
    }
    
    .nav-link:hover {
        transform: none;
        box-shadow: 2px 2px 0px 0px rgba(0,0,0,1);
    }
    
    /* Footer spacing */
    footer.neo-brutal {
        padding: 1rem;
        margin-top: 1rem;
    }
    
    /* TLD carousel on mobile */
    .tld-carousel {
        padding: 0.5rem 0;
    }
    
    .tld-logo-item {
        margin: 0 0.5rem;
    }
    
    .tld-logo-item .bg-white {
        height: 60px;
        width: 80px;
        padding: 0.5rem;
    }
    
    .tld-logo-item img {
        max-height: 40px;
        max-width: 60px;
    }
    
    .tld-logo-item span {
        font-size: 0.75rem;
        margin-top: 0.25rem;
    }
    
    /* Stats grid improvements */
    .neo-stats-sm {
        padding: 0.5rem;
        font-size: 0.875rem;
        border: 1px solid #000;
        box-shadow: 1px 1px 0px 0px rgba(0,0,0,1);
    }
    
    /* About section mobile optimization */
    .prose {
        font-size: 0.875rem;
        line-height: 1.5;
    }
    
    .prose p {
        margin-bottom: 0.75rem;
    }
    
    .prose ul {
        margin-left: 1rem;
        margin-bottom: 0.75rem;
    }
    
    /* Domain title mobile optimization */
    .domain-title {
        font-size: 1.125rem;
        gap: 0.5rem;
        margin-bottom: 0.75rem;
    }
    
    .domain-title img {
        width: 20px;
        height: 20px;
    }
    
    /* Table responsiveness */
    .overflow-x-auto {
        font-size: 0.875rem;
    }
    
    table th,
    table td {
        padding: 0.5rem;
        font-size: 0.875rem;
    }
    
    /* Dark mode mobile adjustments */
    [data-theme="dark"] .neo-brutal,
    [data-theme="dark"] .neo-brutal-sm,
    [data-theme="dark"] .neo-card {
        border-color: #666;
    }
    
    [data-theme="dark"] .neo-input,
    [data-theme="dark"] .neo-btn {
        border-color: #666 !important;
    }
    
    [data-theme="dark"] .tab-btn {
        border-color: #666;
    }
    
    [data-theme="dark"] .nav-link {
        border-color: #666;
    }
}

/* Mobile menu styles */
.mobile-menu {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 1000;
    overflow: hidden;
}

.mobile-menu.active {
    display: block;
}

.mobile-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    background-color: #ff5757;
    color: white;
    border-bottom: 2px solid #000;
}

.mobile-menu-close {
    font-size: 20px;
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    padding: 0;
}

.mobile-menu-content {
    background-color: white;
    max-width: 480px;
    margin: 0 auto;
    padding: 12px;
    box-shadow: 4px 4px 0px 0px rgba(0,0,0,1);
    border: 2px solid #000;
}

.mobile-menu-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-bottom: 8px;
}

.mobile-menu-switchers {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-top: 8px;
}

.mobile-menu-item {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    background-color: white;
    border: 2px solid #000;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    color: inherit;
    height: 46px;
}

.mobile-menu-item:hover {
    transform: translate(-2px, -2px);
    box-shadow: 4px 4px 0px 0px rgba(0,0,0,1);
}

.mobile-menu-item.active {
    background-color: #ff5757;
    color: white;
}

[data-theme="dark"] .mobile-menu {
    background-color: rgba(0, 0, 0, 0.9);
}

[data-theme="dark"] .mobile-menu-content {
    background-color: #333;
    color: white;
    border-color: #555;
}

[data-theme="dark"] .mobile-menu-item {
    background-color: #444;
    color: white;
    border-color: #555;
}

[data-theme="dark"] .mobile-menu-item.active {
    background-color: #ff5757;
}

/* Mobile responsive styles */
@media (max-width: 768px) {
    .mobile-menu-btn {
        display: flex;
    }
    
    .mobile-menu {
        display: block;
    }
    
    .desktop-nav {
        display: none;
    }
    
    .site-title {
        font-size: 1.25rem;
    }
}

/* Mobile menu styles */
.mobile-menu-btn {
    display: block;
    border: 2px solid #000;
    background: #fff;
    padding: 0.5rem;
    cursor: pointer;
    box-shadow: 3px 3px 0px 0px rgba(0,0,0,1);
    transition: all 0.2s ease;
}

.mobile-menu-btn:hover {
    transform: translate(-2px, -2px);
    box-shadow: 5px 5px 0px 0px rgba(0,0,0,1);
}

[data-theme="dark"] .mobile-menu-btn {
    background: #2a2a2a;
    border-color: #fff;
    color: #fff;
}

.mobile-menu {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 1000;
    overflow: hidden;
}

.mobile-menu.active {
    display: block;
}

/* Explicit duration for Swup transitions */
[class*="transition-"] {
  transition-duration: 0.3s; /* Adjust duration as needed */
}

/* Additional mobile responsive utilities */
@media (max-width: 480px) {
    /* Ultra-mobile optimizations for very small screens */
    body {
        padding: 0.25rem;
    }
    
    /* Single column layout for tabs on very small screens */
    .grid-cols-1.sm\:grid-cols-2.lg\:grid-cols-4 {
        grid-template-columns: 1fr;
        gap: 0.25rem;
    }
    
    /* Reduce margins and padding further */
    .neo-brutal {
        margin-bottom: 0.5rem;
        padding: 0.75rem;
    }
    
    .neo-brutal-sm {
        margin-bottom: 0.25rem;
        padding: 0.5rem;
    }
    
    /* Smaller text for very small screens */
    .text-4xl {
        font-size: 1.5rem;
    }
    
    .text-2xl {
        font-size: 1.25rem;
    }
    
    .text-xl {
        font-size: 1.125rem;
    }
    
    /* Compact header */
    header .neo-brutal {
        padding: 0.5rem;
        margin-bottom: 0.5rem;
    }
    
    .site-title {
        font-size: 1rem;
    }
    
    /* Compact tool content */
    #tabContent {
        padding: 0.75rem;
        margin-top: 0.25rem;
    }
    
    /* Form elements more compact */
    .neo-input,
    .neo-btn {
        padding: 0.5rem;
        font-size: 14px;
    }
    
    /* Tab buttons more compact */
    .tab-btn {
        padding: 0.75rem;
        min-height: 3rem;
        font-size: 0.875rem;
    }
    
    /* Compact stats */
    .neo-stats-sm {
        padding: 0.375rem;
        font-size: 0.75rem;
    }
    
    /* Domain title compact */
    .domain-title {
        font-size: 1rem;
        gap: 0.25rem;
        margin-bottom: 0.5rem;
    }
    
    .domain-title img {
        width: 16px;
        height: 16px;
    }
    
    /* Mobile menu more compact */
    .mobile-menu-item {
        padding: 0.75rem;
        height: 40px;
        font-size: 0.875rem;
    }
    
    /* TLD carousel more compact */
    .tld-logo-item .bg-white {
        height: 50px;
        width: 70px;
        padding: 0.25rem;
    }
    
    .tld-logo-item img {
        max-height: 35px;
        max-width: 50px;
    }
    
    .tld-logo-item span {
        font-size: 0.7rem;
        margin-top: 0.125rem;
    }
}

/* Utility class for mobile-only hidden borders */
@media (max-width: 768px) {
    .mobile-no-border {
        border: none !important;
        box-shadow: none !important;
    }
    
    .mobile-simple-border {
        border: 1px solid #ccc !important;
        box-shadow: none !important;
        border-radius: 4px !important;
    }
}

/* Fix overflow issues on mobile */
@media (max-width: 768px) {
    * {
        box-sizing: border-box;
    }
    
    .container {
        max-width: 100%;
        overflow-x: hidden;
    }
    
    /* Hide about sections on mobile to save space */
    .tool-about-section {
        display: none !important;
    }
    
    /* Ensure tables don't break layout */
    .table-responsive {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    table {
        min-width: 100%;
        white-space: nowrap;
    }
    
    /* Prevent code blocks from overflowing */
    pre {
        overflow-x: auto;
        white-space: pre-wrap;
        word-wrap: break-word;
    }
    
    /* Ensure long URLs break properly */
    .break-words {
        word-break: break-all;
        overflow-wrap: break-word;
    }
} 