/*
Theme Name: Subdomain Selector
Theme URI: https://example.com
Author: Your Name
Author URI: https://example.com
Description: A modern WordPress theme for selecting and navigating between pages from different subdomains.
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: subdomain-selector
Tags: modern, clean, responsive, subdomain
*/

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Color Palette */
    --color-primary: #2563eb;
    --color-primary-dark: #1e40af;
    --color-primary-light: #3b82f6;
    --color-text: #1f2937;
    --color-text-light: #6b7280;
    --color-bg: #f9fafb;
    --color-white: #ffffff;
    --color-border: #e5e7eb;
    --color-success: #10b981;
    --color-hover: #f3f4f6;
    
    /* Typography */
    --font-sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --font-size-base: 16px;
    --line-height-base: 1.6;
    
    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 1.5rem;
    --spacing-lg: 2rem;
    --spacing-xl: 3rem;
    --spacing-2xl: 4rem;
    
    /* Layout */
    --max-width: 1200px;
    --border-radius: 8px;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

body {
    font-family: var(--font-sans);
    font-size: var(--font-size-base);
    line-height: var(--line-height-base);
    color: var(--color-text);
    background-color: var(--color-bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: var(--spacing-sm);
    color: var(--color-text);
}

h1 {
    font-size: 2.5rem;
}

h2 {
    font-size: 2rem;
}

h3 {
    font-size: 1.5rem;
}

p {
    margin-bottom: var(--spacing-sm);
}

a {
    color: var(--color-primary);
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: var(--color-primary-dark);
}

/* Layout */
.site {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.site-container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 var(--spacing-md);
    width: 100%;
}

.site-main {
    flex: 1;
    padding: var(--spacing-xl) 0;
}

/* Header */
.site-header {
    background-color: var(--color-white);
    border-bottom: 1px solid var(--color-border);
    padding: var(--spacing-md) 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--shadow-sm);
}

.site-branding {
    text-align: center;
}

.site-title {
    font-size: 1.75rem;
    margin: 0;
}

.site-title a {
    color: var(--color-text);
}

.site-title a:hover {
    color: var(--color-primary);
}

.site-description {
    font-size: 0.9rem;
    color: var(--color-text-light);
    margin-top: var(--spacing-xs);
}

/* Subdomain Selector */
.subdomain-selector {
    max-width: 900px;
    margin: 0 auto;
}

.subdomain-selector-header {
    text-align: center;
    margin-bottom: var(--spacing-xl);
}

.subdomain-selector-header h1 {
    font-size: 2.5rem;
    margin-bottom: var(--spacing-sm);
}

.subdomain-selector-header p {
    font-size: 1.125rem;
    color: var(--color-text-light);
    max-width: 600px;
    margin: 0 auto;
}

.subdomain-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 280px));
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-lg);
    justify-content: center;
}

.subdomain-card {
    background-color: var(--color-white);
    border: 2px solid var(--card-color, var(--color-primary));
    border-radius: var(--border-radius);
    padding: var(--spacing-lg);
    transition: all 0.3s ease;
    cursor: pointer;
    text-align: center;
    box-shadow: var(--shadow-sm);
    position: relative;
    overflow: hidden;
}

.subdomain-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background-color: var(--card-color, var(--color-primary));
    transition: height 0.3s ease, opacity 0.3s ease;
    opacity: 1;
    z-index: 0;
}

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

.subdomain-card:hover::before {
    height: 100%;
    opacity: 0.05;
}

.subdomain-card > * {
    position: relative;
    z-index: 1;
}

.subdomain-card.active {
    border-color: var(--card-color, var(--color-primary));
    background-color: rgba(37, 99, 235, 0.05);
}

.subdomain-card h3 {
    font-size: 1.25rem;
    margin-bottom: var(--spacing-xs);
    color: var(--color-text);
}

.subdomain-card p {
    font-size: 0.9rem;
    color: var(--color-text-light);
    margin-bottom: var(--spacing-md);
}

.subdomain-card-url {
    font-size: 0.85rem;
    color: var(--card-color, var(--color-primary));
    font-family: 'Courier New', monospace;
    word-break: break-all;
    margin-top: var(--spacing-sm);
}

.subdomain-form {
    background-color: var(--color-white);
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius);
    padding: var(--spacing-lg);
    box-shadow: var(--shadow-sm);
    max-width: 600px;
    margin: 0 auto;
}

.subdomain-form h2 {
    font-size: 1.5rem;
    margin-bottom: var(--spacing-md);
    text-align: center;
}

.form-group {
    margin-bottom: var(--spacing-md);
}

.form-group label {
    display: block;
    margin-bottom: var(--spacing-xs);
    font-weight: 500;
    color: var(--color-text);
}

.form-group input,
.form-group select {
    width: 100%;
    padding: var(--spacing-sm);
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius);
    font-size: var(--font-size-base);
    font-family: var(--font-sans);
    transition: border-color 0.2s ease;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.form-group input[type="url"] {
    font-family: 'Courier New', monospace;
}

.button {
    display: inline-block;
    padding: var(--spacing-sm) var(--spacing-lg);
    background-color: var(--color-primary);
    color: var(--color-white);
    border: none;
    border-radius: var(--border-radius);
    font-size: var(--font-size-base);
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s ease;
    width: 100%;
    text-align: center;
}

.button:hover {
    background-color: var(--color-primary-dark);
}

.button:active {
    transform: scale(0.98);
}

.button-secondary {
    background-color: var(--color-white);
    color: var(--color-primary);
    border: 1px solid var(--color-primary);
}

.button-secondary:hover {
    background-color: var(--color-hover);
}

/* Footer */
.site-footer {
    background-color: var(--color-white);
    border-top: 1px solid var(--color-border);
    padding: var(--spacing-md) 0;
    margin-top: auto;
    text-align: center;
    font-size: 0.9rem;
    color: var(--color-text-light);
}

.site-footer a {
    color: var(--color-text-light);
}

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

/* Responsive Design */
@media (max-width: 768px) {
    :root {
        --spacing-xl: 2rem;
        --spacing-2xl: 3rem;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    .subdomain-selector-header h1 {
        font-size: 2rem;
    }
    
    .subdomain-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-sm);
    }
    
    .subdomain-card {
        padding: var(--spacing-md);
    }
    
    .site-container {
        padding: 0 var(--spacing-sm);
    }
}

@media (max-width: 480px) {
    .subdomain-selector-header h1 {
        font-size: 1.75rem;
    }
    
}

