/* Custom Subdomain Plugin Styles */

#playsub-form-container {
    max-width: 600px;
    margin: 20px auto;
    padding: 30px;
    background: #fff;
    border-radius: 8px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

#playsub-form-container h3 {
    color: #333;
    margin-bottom: 25px;
    font-size: 24px;
    text-align: center;
    border-bottom: 2px solid #0073aa;
    padding-bottom: 10px;
}

.playsub-form-group {
    margin-bottom: 20px;
}

.playsub-form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: #555;
    font-size: 14px;
}

.playsub-form-group input,
.playsub-form-group textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid #ddd;
    border-radius: 5px;
    font-size: 16px;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    box-sizing: border-box;
}

.playsub-form-group input:focus,
.playsub-form-group textarea:focus {
    outline: none;
    border-color: #0073aa;
    box-shadow: 0 0 0 3px rgba(0,115,170,0.1);
}

.playsub-subdomain-input {
    display: flex;
    align-items: center;
    border: 2px solid #ddd;
    border-radius: 5px;
    overflow: hidden;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.playsub-subdomain-input:focus-within {
    border-color: #0073aa;
    box-shadow: 0 0 0 3px rgba(0,115,170,0.1);
}

.playsub-subdomain-input input {
    border: none;
    padding: 12px;
    flex: 1;
    font-size: 16px;
}

.playsub-subdomain-input input:focus {
    box-shadow: none;
}

.playsub-subdomain-input span {
    background: #f8f9fa;
    padding: 12px 15px;
    color: #666;
    font-weight: 500;
    border-left: 1px solid #ddd;
    white-space: nowrap;
}

.playsub-form-group small {
    display: block;
    margin-top: 5px;
    color: #666;
    font-size: 12px;
}

.playsub-form-group button {
    background: linear-gradient(135deg, #0073aa 0%, #005177 100%);
    color: white;
    padding: 15px 30px;
    border: none;
    border-radius: 5px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    width: 100%;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.playsub-form-group button:hover {
    background: linear-gradient(135deg, #005177 0%, #003d5c 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0,115,170,0.3);
}

.playsub-form-group button:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* Message Styles */
#playsub-message {
    margin: 20px 0;
    padding: 15px;
    border-radius: 5px;
    font-weight: 500;
}

#playsub-message.playsub-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

#playsub-message.playsub-error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

#playsub-message p {
    margin: 0;
}

/* User Profile Styles */
.playsub-user-profile {
    max-width: 800px;
    margin: 20px auto;
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    overflow: hidden;
}

.playsub-user-header {
    background: linear-gradient(135deg, #0073aa 0%, #005177 100%);
    color: white;
    padding: 40px 30px;
    text-align: center;
}

.playsub-user-header h2 {
    margin: 0 0 10px 0;
    font-size: 28px;
    font-weight: 300;
}

.playsub-subdomain-url {
    margin: 0;
    font-size: 16px;
    opacity: 0.9;
    font-family: monospace;
    background: rgba(255,255,255,0.1);
    padding: 8px 16px;
    border-radius: 20px;
    display: inline-block;
}

.playsub-user-info {
    padding: 30px;
}

.playsub-info-item {
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.playsub-info-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.playsub-info-item strong {
    color: #333;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: block;
    margin-bottom: 5px;
}

.playsub-info-item a {
    color: #0073aa;
    text-decoration: none;
    font-weight: 500;
}

.playsub-info-item a:hover {
    text-decoration: underline;
}

.playsub-info-item p {
    margin: 5px 0 0 0;
    line-height: 1.6;
    color: #555;
}

/* Character Counter */
.char-counter {
    color: #666;
    font-size: 11px;
    float: right;
    margin-top: 5px;
}

.char-counter.over-limit {
    color: #dc3232;
    font-weight: bold;
}

/* Responsive Design */
@media (max-width: 768px) {
    #playsub-form-container,
    .playsub-user-profile {
        margin: 10px;
        padding: 20px;
    }
    
    .playsub-user-header {
        padding: 30px 20px;
    }
    
    .playsub-user-header h2 {
        font-size: 24px;
    }
    
    .playsub-subdomain-input {
        flex-direction: column;
    }
    
    .playsub-subdomain-input span {
        border-left: none;
        border-top: 1px solid #ddd;
        text-align: center;
    }
}

/* Loading Animation */
.playsub-form-group button:disabled::after {
    content: "";
    display: inline-block;
    width: 16px;
    height: 16px;
    margin-left: 10px;
    border: 2px solid transparent;
    border-top: 2px solid currentColor;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Validation Styles */
.playsub-form-group input.error,
.playsub-form-group textarea.error {
    border-color: #dc3232;
    box-shadow: 0 0 0 3px rgba(220,50,50,0.1);
}

.playsub-form-group input.success,
.playsub-form-group textarea.success {
    border-color: #46b450;
    box-shadow: 0 0 0 3px rgba(70,180,80,0.1);
}

/* Tooltip Styles */
.playsub-tooltip {
    position: relative;
    display: inline-block;
}

.playsub-tooltip .tooltiptext {
    visibility: hidden;
    width: 200px;
    background-color: #333;
    color: #fff;
    text-align: center;
    border-radius: 6px;
    padding: 5px 10px;
    position: absolute;
    z-index: 1;
    bottom: 125%;
    left: 50%;
    margin-left: -100px;
    opacity: 0;
    transition: opacity 0.3s;
    font-size: 12px;
}

.playsub-tooltip:hover .tooltiptext {
    visibility: visible;
    opacity: 1;
}

/* Admin Styles */
.wp-admin .status-active {
    color: #46b450;
    font-weight: bold;
}

.wp-admin .status-inactive {
    color: #dc3232;
    font-weight: bold;
}