/* NetToolkit.eu - Styles */

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

:root {
    --primary-color: #2563eb;
    --primary-hover: #1d4ed8;
    --secondary-color: #64748b;
    --success-color: #10b981;
    --error-color: #ef4444;
    --warning-color: #f59e0b;
    --bg-color: #f8fafc;
    --card-bg: #ffffff;
    --border-color: #e2e8f0;
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);
}

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

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

/* Header */
header {
    background: linear-gradient(135deg, var(--primary-color) 0%, #1d4ed8 100%);
    color: white;
    padding: 2rem 0;
    box-shadow: var(--shadow-lg);
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

header .tagline {
    font-size: 1.1rem;
    opacity: 0.9;
}

/* Navigation */
nav {
    background: var(--card-bg);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-categories {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    padding: 1rem 0;
}

.nav-categories li a {
    display: block;
    padding: 0.75rem 1.5rem;
    color: var(--text-secondary);
    text-decoration: none;
    border-radius: 0.5rem;
    transition: all 0.2s;
    font-weight: 500;
}

.nav-categories li a:hover,
.nav-categories li a.active {
    background-color: var(--primary-color);
    color: white;
}

/* Main Content */
main {
    padding: 2rem 0;
    min-height: 60vh;
}

.tool-category {
    display: none;
    margin-bottom: 2rem;
}

.tool-category.active {
    display: block;
}

.tool-category h2 {
    font-size: 2rem;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

/* Tool Grid */
.tool-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.tool-card {
    background: var(--card-bg);
    border: 2px solid var(--border-color);
    border-radius: 0.75rem;
    padding: 1.5rem;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: var(--shadow);
}

.tool-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-color);
}

.tool-card.active {
    border-color: var(--primary-color);
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
}

.tool-card.coming-soon {
    opacity: 0.6;
    cursor: not-allowed;
}

.tool-card.coming-soon:hover {
    transform: none;
    border-color: var(--border-color);
}

.tool-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.tool-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* Tool Interface */
#tool-interface {
    margin-top: 2rem;
}

.tool-interface {
    display: none;
}

.tool-interface.active {
    display: block;
}

.tool-header {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 0.75rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow);
}

.tool-header h2 {
    font-size: 1.75rem;
    margin-bottom: 0.5rem;
}

.tool-header p {
    color: var(--text-secondary);
}

/* Forms */
form {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 0.75rem;
    box-shadow: var(--shadow);
}

.form-section {
    margin-bottom: 2rem;
}

.form-section h3 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.checkbox-group {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 0.75rem;
}

.checkbox-group label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 0.375rem;
    transition: background-color 0.2s;
}

.checkbox-group label:hover {
    background-color: var(--bg-color);
}

.checkbox-group input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

/* Input Method Tabs */
.input-method-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.tab-btn {
    padding: 0.75rem 1.5rem;
    border: 2px solid var(--border-color);
    background: white;
    border-radius: 0.5rem;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.2s;
}

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

.tab-btn.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.input-method {
    display: none;
}

.input-method.active {
    display: block;
}

/* Form Controls */
label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--text-primary);
}

textarea,
input[type="file"] {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid var(--border-color);
    border-radius: 0.5rem;
    font-family: inherit;
    font-size: 0.95rem;
    transition: border-color 0.2s;
}

textarea:focus,
input[type="file"]:focus {
    outline: none;
    border-color: var(--primary-color);
}

textarea {
    resize: vertical;
    font-family: 'Courier New', monospace;
}

small {
    display: block;
    margin-top: 0.5rem;
    color: var(--text-secondary);
    font-size: 0.875rem;
}

/* Buttons */
.btn-primary,
.btn-secondary {
    padding: 1rem 2rem;
    border: none;
    border-radius: 0.5rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-primary {
    background: var(--primary-color);
    color: white;
    width: 100%;
    justify-content: center;
}

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

.btn-primary:disabled {
    background: var(--secondary-color);
    cursor: not-allowed;
    transform: none;
}

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

.btn-secondary:hover {
    background: #475569;
}

/* Results */
#results-container {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 0.75rem;
    box-shadow: var(--shadow);
    margin-top: 2rem;
}

.results-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.results-header h3 {
    font-size: 1.5rem;
}

.results-actions {
    display: flex;
    gap: 0.75rem;
}

.status-info {
    background: var(--bg-color);
    padding: 1rem;
    border-radius: 0.5rem;
    margin-bottom: 1.5rem;
    border-left: 4px solid var(--primary-color);
}

.status-info.success {
    border-left-color: var(--success-color);
}

.status-info.error {
    border-left-color: var(--error-color);
}

/* Results Table */
.results-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1rem;
}

.results-table th,
.results-table td {
    padding: 0.75rem;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.results-table th {
    background: var(--bg-color);
    font-weight: 600;
    color: var(--text-primary);
}

.results-table tr:hover {
    background: var(--bg-color);
}

.status-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.875rem;
    font-weight: 500;
}

.status-badge.success {
    background: #d1fae5;
    color: #065f46;
}

.status-badge.error {
    background: #fee2e2;
    color: #991b1b;
}

.result-data {
    font-family: 'Courier New', monospace;
    font-size: 0.875rem;
    max-width: 400px;
    overflow-x: auto;
}

/* Footer */
footer {
    background: var(--text-primary);
    color: white;
    padding: 2rem 0;
    margin-top: 4rem;
    text-align: center;
}

/* Responsive */
@media (max-width: 768px) {
    header h1 {
        font-size: 2rem;
    }

    .nav-categories {
        flex-direction: column;
    }

    .checkbox-group {
        grid-template-columns: 1fr;
    }

    .results-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .results-table {
        font-size: 0.875rem;
    }

    .results-table th,
    .results-table td {
        padding: 0.5rem;
    }
}

/* Loading Animation */
@keyframes spin {
    to { transform: rotate(360deg); }
}

.btn-loader::before {
    content: '';
    display: inline-block;
    width: 1rem;
    height: 1rem;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
    margin-right: 0.5rem;
}
