/* TK Racing User Account Styles - Dark Theme Compatible */

.tk-racing-user-account {
    max-width: 1200px;
    min-width: 500px;
    margin: 0 auto;
    padding: 20px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Mobile responsive - remove min-width on mobile */
@media (max-width: 768px) {
    .tk-racing-user-account {
        min-width: auto;
    }
}

/* Header */
.tk-racing-account-header {
    text-align: center;
    margin-bottom: 30px;
}

.tk-racing-account-title,
.tk-racing-dashboard-title {
    color: #ffffff;
    font-size: 2rem;
    margin: 0;
    font-weight: 600;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

/* Tabs */
.tk-racing-account-tabs {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.tk-racing-tab-nav {
    display: flex;
    background: rgba(255, 255, 255, 0.05);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.tk-racing-tab-link {
    flex: 1;
    padding: 15px 20px;
    text-align: center;
    text-decoration: none;
    color: #b0b0b0;
    font-weight: 500;
    transition: all 0.3s ease;
    border-bottom: 3px solid transparent;
}

.tk-racing-tab-link:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.1);
}

.tk-racing-tab-link.active {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.15);
    border-bottom-color: #007cba;
}

.tk-racing-tab-content {
    padding: 30px;
}

/* Account Forms - Different from submission form to avoid conflicts */
.tk-racing-account-form {
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 30px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
}

/* Login/Register Forms */
.tk-racing-login-form,
.tk-racing-register-form {
    /* Container styling handled by .tk-racing-account-form */
}

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

/* Account form inputs - dark theme */
.tk-racing-account-form input[type="text"],
.tk-racing-account-form input[type="email"],
.tk-racing-account-form input[type="password"] {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    font-size: 14px;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.tk-racing-account-form input[type="text"]:focus,
.tk-racing-account-form input[type="email"]:focus,
.tk-racing-account-form input[type="password"]:focus {
    outline: none;
    border-color: #007cba;
    background: rgba(255, 255, 255, 0.15);
    box-shadow: 0 0 0 2px rgba(0, 124, 186, 0.3);
}

.tk-racing-account-form input[type="text"]::placeholder,
.tk-racing-account-form input[type="email"]::placeholder,
.tk-racing-account-form input[type="password"]::placeholder {
    color: #b0b0b0;
}

.tk-racing-account-form label {
    display: block;
    margin-bottom: 8px;
    color: #ffffff;
    font-weight: 500;
    font-size: 14px;
}

.tk-racing-form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
    color: #ffffff;
}

.tk-racing-form-group input[type="text"],
.tk-racing-form-group input[type="email"],
.tk-racing-form-group input[type="password"] {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 8px;
    font-size: 16px;
    transition: all 0.3s ease;
    box-sizing: border-box;
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    backdrop-filter: blur(10px);
}

.tk-racing-form-group input[type="text"]:focus,
.tk-racing-form-group input[type="email"]:focus,
.tk-racing-form-group input[type="password"]:focus {
    outline: none;
    border-color: #007cba;
    box-shadow: 0 0 0 2px rgba(0, 124, 186, 0.3);
    background: rgba(255, 255, 255, 0.15);
}

.tk-racing-form-group input[type="text"]::placeholder,
.tk-racing-form-group input[type="email"]::placeholder,
.tk-racing-form-group input[type="password"]::placeholder {
    color: #b0b0b0;
}

.tk-racing-checkbox-label {
    display: flex;
    align-items: center;
    font-weight: normal;
    cursor: pointer;
}

.tk-racing-checkbox-label input[type="checkbox"] {
    margin-right: 8px;
}

/* Buttons */
.tk-racing-btn {
    display: inline-block;
    padding: 12px 24px;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 500;
    text-decoration: none;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.tk-racing-btn-primary {
    background: #c9102e;
    color: #fff !important;
    width: 100%;
}

.tk-racing-btn-primary:hover {
    background: #005a87;
    color: #fff;
}

.tk-racing-btn-small {
    padding: 6px 12px;
    font-size: 14px;
    width: auto;
}

.tk-racing-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Messages */
.tk-racing-form-messages {
    margin-top: 15px;
    padding: 10px;
    border-radius: 4px;
    display: none;
}

.tk-racing-form-messages.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
    display: block;
}

.tk-racing-form-messages.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
    display: block;
}

.tk-racing-form-messages.error a {
    color: #721c24;
    text-decoration: underline;
}

.tk-racing-form-messages.error a:hover {
    color: #C8102E !important;
}

/* Dashboard */
.tk-racing-user-dashboard {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
}

.tk-racing-dashboard-header {
    background: rgba(255, 255, 255, 0.05);
    padding: 20px 30px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.tk-racing-section-title {
    margin: 0 0 20px 0;
    color: #ffffff;
    font-size: 1.25rem;
    font-weight: 600;
}

.tk-racing-activity-section-title {
    margin: 0 0 15px 0;
    color: #ffffff;
    font-size: 1.1rem;
}

.tk-racing-user-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.tk-racing-welcome {
    color: #b0b0b0;
    font-weight: 500;
}

.tk-racing-logout-link {
    color: #dc3545;
    text-decoration: none;
    font-weight: 500;
    padding: 8px 16px;
    border: 1px solid #dc3545;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.tk-racing-logout-link:hover {
    background: #dc3545;
    color: #fff;
}

.tk-racing-dashboard-content {
    display: flex;
    min-height: 500px;
}

/* Sidebar */
.tk-racing-dashboard-sidebar {
    width: 250px;
    background: rgba(255, 255, 255, 0.05);
    border-right: 1px solid rgba(255, 255, 255, 0.1);
}

.tk-racing-dashboard-nav {
    padding: 20px 0;
}

.tk-racing-nav-item {
    display: flex;
    align-items: center;
    padding: 15px 20px;
    color: #b0b0b0;
    text-decoration: none;
    transition: all 0.3s ease;
    border-left: 3px solid transparent;
}

.tk-racing-nav-item:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

.tk-racing-nav-item.active {
    background: rgba(255, 255, 255, 0.15);
    color: #007cba;
    border-left-color: #007cba;
}

.tk-racing-nav-icon {
    margin-right: 12px;
    font-size: 18px;
    width: 20px;
    text-align: center;
    display: inline-block;
}

.tk-racing-nav-title {
    font-weight: 500;
}

/* Main Content */
.tk-racing-dashboard-main {
    flex: 1;
    padding: 30px;
}

/* Account Details */
.tk-racing-account-details {
    margin-bottom: 30px;
}

.tk-racing-account-info {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
}

.tk-racing-info-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.tk-racing-info-item:last-child {
    border-bottom: none;
}

.tk-racing-info-item label {
    color: #ffffff;
    font-weight: 500;
    margin: 0;
}

.tk-racing-info-item span {
    color: #b0b0b0;
}

/* Account Edit Form */
.tk-racing-account-edit {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
}

.tk-racing-form {
    background: transparent;
    border: none;
}

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

.tk-racing-form-group label {
    display: block;
    color: #ffffff;
    font-weight: 500;
    margin-bottom: 8px;
}

.tk-racing-form-group input {
    width: 100%;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    color: #ffffff;
    font-size: 14px;
    transition: all 0.3s ease;
}

.tk-racing-form-group input:focus {
    outline: none;
    border-color: #007cba;
    background: rgba(255, 255, 255, 0.15);
}

.tk-racing-form-group input::placeholder {
    color: #b0b0b0;
}

/* Account Actions */
.tk-racing-account-actions {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 20px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
}

.tk-racing-action-buttons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}


/* Dashboard Overview */
.tk-racing-overview-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.tk-racing-stat-item {
    background: rgba(255, 255, 255, 0.1);
    padding: 20px;
    border-radius: 8px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
}

.tk-racing-stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 5px;
}

.tk-racing-stat-label {
    color: #b0b0b0;
    font-size: 0.9rem;
    font-weight: 500;
}

/* Dashboard Actions */
.tk-racing-dashboard-actions {
    margin: 30px 0;
    text-align: center;
}

.tk-racing-dashboard-actions .tk-racing-btn {
    width: auto;
    padding: 15px 30px;
    font-size: 16px;
    font-weight: 600;
}

/* Recent Activity */

.tk-racing-activity-list {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 20px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
}

.tk-racing-activity-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.tk-racing-activity-item:last-child {
    border-bottom: none;
}

.tk-racing-activity-date {
    color: #b0b0b0;
    font-size: 0.9rem;
}

.tk-racing-activity-description {
    color: #ffffff;
    font-weight: 500;
}

/* Activity Actions */
.tk-racing-activity-actions {
    margin-top: 20px;
    text-align: center;
}

.tk-racing-activity-actions .tk-racing-btn {
    width: auto;
    padding: 12px 24px;
    font-size: 14px;
}

/* Submissions Table */
.tk-racing-submissions-table {
    overflow-x: auto;
}

.tk-racing-submissions-table table {
    width: 100%;
    border-collapse: collapse;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.tk-racing-submissions-table th,
.tk-racing-submissions-table td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.tk-racing-submissions-table th {
    background: rgba(255, 255, 255, 0.1);
    font-weight: 600;
    color: #ffffff;
}

.tk-racing-submissions-table td {
    color: #e0e0e0;
}

.tk-racing-submissions-table tr:hover {
    background: rgba(255, 255, 255, 0.05);
}

/* Status */
.tk-racing-status {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 500;
    text-transform: uppercase;
}

.tk-racing-status-publish {
    background: #d4edda;
    color: #155724;
}

.tk-racing-status-draft {
    background: #fff3cd;
    color: #856404;
}

.tk-racing-status-pending {
    background: #cce5ff;
    color: #004085;
}

/* Account Info */
.tk-racing-account-info {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.tk-racing-info-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.tk-racing-info-item:last-child {
    border-bottom: none;
}

.tk-racing-info-item label {
    font-weight: 600;
    color: #ffffff;
    margin: 0;
}

.tk-racing-info-item span {
    color: #b0b0b0;
}

/* Password Change */
.tk-racing-password-change .tk-racing-form {
    max-width: 500px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 30px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
}

.tk-racing-password-change .tk-racing-form-group input[type="password"] {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: #ffffff;
    backdrop-filter: blur(10px);
}

.tk-racing-password-change .tk-racing-form-group input[type="password"]:focus {
    background: rgba(255, 255, 255, 0.15);
    border-color: #007cba;
    box-shadow: 0 0 0 2px rgba(0, 124, 186, 0.3);
}

.tk-racing-password-change .tk-racing-form-group input[type="password"]::placeholder {
    color: #b0b0b0;
}

.tk-racing-password-info {
    margin-bottom: 30px;
}

.tk-racing-info-box {
    background: rgba(0, 124, 186, 0.1);
    border: 1px solid rgba(0, 124, 186, 0.3);
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
}

.tk-racing-info-title {
    font-weight: 600;
    color: #007cba;
    margin-bottom: 10px;
}

.tk-racing-requirements-list {
    margin: 0;
    padding-left: 20px;
    color: #e0e0e0;
}

.tk-racing-requirements-list li {
    margin-bottom: 5px;
}

.tk-racing-field-help {
    font-size: 0.9rem;
    color: #b0b0b0;
    margin-top: 5px;
    font-style: italic;
}

.tk-racing-password-tips {
    margin-top: 40px;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.tk-racing-tips-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.tk-racing-tip-item {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 20px;
}

.tk-racing-tip-title {
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 8px;
}

.tk-racing-tip-text {
    color: #b0b0b0;
    font-size: 0.9rem;
    line-height: 1.4;
}

/* Account Actions */
.tk-racing-account-actions {
    margin-top: 30px;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.tk-racing-action-buttons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.tk-racing-btn-secondary {
    background: #28a745;
    color: #fff !important;
    border: 1px solid #28a745;
    width: 100%;
}

.tk-racing-btn-secondary:hover {
    background: #218838;
    color: #fff;
    border-color: #1e7e34;
}

/* PDF Download Button */
.tk-racing-pdf-download-btn {
    background: #007cba;
    color: #ffffff;
    border: none;
    border-radius: 6px;
    padding: 8px 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
}

.tk-racing-pdf-download-btn:hover {
    background: #005a87;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 124, 186, 0.3);
}

.tk-racing-pdf-download-btn i {
    font-size: 16px;
}

/* No Submissions State */
.tk-racing-no-submissions {
    text-align: center;
    padding: 60px 20px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.tk-racing-no-submissions-icon {
    font-size: 4rem;
    color: #b0b0b0;
    margin-bottom: 20px;
}

.tk-racing-no-submissions-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 10px;
}

.tk-racing-no-submissions-text {
    color: #b0b0b0;
    margin-bottom: 30px;
    font-size: 1.1rem;
}

.tk-racing-no-submissions-action {
    margin-top: 20px;
}

/* Desktop - Minimum Width */
@media (min-width: 769px) {
    .tk-racing-user-dashboard {
        min-width: 900px;
    }
}

/* Responsive */
@media (max-width: 768px) {
    .tk-racing-dashboard-content {
        flex-direction: column;
    }
    
    .tk-racing-dashboard-sidebar {
        width: 100%;
        border-right: none;
        border-bottom: 1px solid #e9ecef;
    }
    
    .tk-racing-dashboard-nav {
        display: flex;
        overflow-x: auto;
        padding: 0;
    }
    
    .tk-racing-nav-item {
        flex-shrink: 0;
        border-left: none;
        border-bottom: 3px solid transparent;
    }
    
    .tk-racing-nav-item.active {
        border-left: none;
        border-bottom-color: #007cba;
    }
    
    .tk-racing-dashboard-header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .tk-racing-overview-stats {
        grid-template-columns: 1fr;
    }
    
    .tk-racing-submissions-table {
        font-size: 0.9rem;
    }
    
    .tk-racing-submissions-table th,
    .tk-racing-submissions-table td {
        padding: 10px 8px;
    }
}

@media (max-width: 480px) {
    .tk-racing-user-account {
        padding: 10px;
    }
    
    .tk-racing-tab-content {
        padding: 20px;
    }
    
    .tk-racing-dashboard-main {
        padding: 20px;
    }
    
    .tk-racing-form-group input[type="text"],
    .tk-racing-form-group input[type="email"],
    .tk-racing-form-group input[type="password"] {
        font-size: 16px; /* Prevent zoom on iOS */
    }
}

/* Events Section Styles */
.tk-racing-events {
    padding: 20px 0;
}

.tk-racing-events-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.tk-racing-event-card {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 20px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.tk-racing-event-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    border-color: rgba(255, 255, 255, 0.3);
}

.tk-racing-event-card.tk-racing-event-card-completed {
    background: rgba(40, 167, 69, 0.15) !important;
    border: 1px solid rgba(40, 167, 69, 0.3) !important;
    box-shadow: 0 4px 16px rgba(40, 167, 69, 0.2) !important;
}

.tk-racing-event-card.tk-racing-event-card-completed:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(40, 167, 69, 0.3) !important;
    border-color: rgba(40, 167, 69, 0.5) !important;
}

.tk-racing-event-header {
    margin-bottom: 15px;
}

.tk-racing-event-title {
    color: #ffffff;
    font-size: 1.2rem;
    font-weight: 600;
    margin: 0 0 8px 0;
    line-height: 1.3;
}

.tk-racing-event-date {
    color: #007cba;
    font-size: 0.9rem;
    font-weight: 500;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.tk-racing-event-content {
    margin-bottom: 20px;
}

.tk-racing-event-description {
    color: #b0b0b0;
    font-size: 0.9rem;
    line-height: 1.5;
}

.tk-racing-event-actions {
    text-align: center;
}

.tk-racing-event-actions .tk-racing-btn {
    width: 100%;
    justify-content: center;
}

.tk-racing-no-events {
    text-align: center;
    padding: 60px 20px;
    color: #b0b0b0;
}

.tk-racing-no-events-icon {
    font-size: 3rem;
    color: #666;
    margin-bottom: 20px;
}

.tk-racing-no-events-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 10px;
}

.tk-racing-no-events-text {
    font-size: 0.9rem;
    line-height: 1.5;
}

/* Responsive Events */
@media (max-width: 768px) {
    .tk-racing-events-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .tk-racing-event-card {
        padding: 15px;
    }
    
    .tk-racing-event-title {
        font-size: 1.1rem;
    }
}
