
/* Tools Specific Styles */

.main-content {
    margin-top: 70px;
    padding: 2rem 0;
    min-height: calc(100vh - 70px);
}

.tool-header {
    text-align: center;
    margin-bottom: 3rem;
    padding: 2rem 0;
}

.tool-icon-large {
    width: 80px;
    height: 80px;
    margin: 0 auto 1rem;
    border-radius: 50%;
    background: var(--primary-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: var(--white);
    box-shadow: var(--shadow-lg);
}

.tool-header h1 {
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1rem;
}

.tool-header p {
    color: var(--gray);
    font-size: 1.125rem;
    max-width: 600px;
    margin: 0 auto;
}

.tool-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

@media (max-width: 968px) {
    .tool-container {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
}

/* Card Styles */
.card {
    background: var(--white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    margin-bottom: 1.5rem;
    border: 1px solid rgba(102, 126, 234, 0.1);
}

.card-header {
    background: var(--light-gray);
    padding: 1.5rem;
    border-bottom: 1px solid rgba(102, 126, 234, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.card-header h2,
.card-header h3 {
    margin: 0;
    color: var(--dark-gray);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.card-body {
    padding: 1.5rem;
}

.btn-clear {
    background: var(--danger-color);
    color: var(--white);
    border: none;
    padding: 0.5rem 1rem;
    border-radius: var(--border-radius-small);
    font-size: 0.875rem;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

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

/* Form Styles */
.subject-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.form-group label {
    font-weight: 600;
    color: var(--dark-gray);
    font-size: 0.875rem;
}

.form-group input,
.form-group select {
    padding: 0.75rem;
    border: 2px solid #e2e8f0;
    border-radius: var(--border-radius-small);
    font-size: 1rem;
    transition: var(--transition);
    background: var(--white);
}

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

.form-group input:invalid {
    border-color: var(--danger-color);
}

/* Table Styles */
.subjects-table-container {
    overflow-x: auto;
}

.subjects-table {
    width: 100%;
    border-collapse: collapse;
    border-radius: var(--border-radius-small);
    overflow: hidden;
    box-shadow: var(--shadow);
}

.subjects-table th,
.subjects-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid #e2e8f0;
}

.subjects-table th {
    background: var(--primary-gradient);
    color: var(--white);
    font-weight: 600;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.subjects-table tbody tr {
    transition: var(--transition);
}

.subjects-table tbody tr:hover {
    background-color: rgba(102, 126, 234, 0.05);
}

.subjects-table td {
    color: var(--dark-gray);
}

.btn-remove {
    background: var(--danger-color);
    color: var(--white);
    border: none;
    padding: 0.5rem;
    border-radius: var(--border-radius-small);
    cursor: pointer;
    transition: var(--transition);
    font-size: 0.875rem;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-remove:hover {
    transform: scale(1.1);
    box-shadow: var(--shadow);
}

/* Results Styles */
.result-card {
    position: sticky;
    top: 90px;
}

.result-display {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.result-item {
    text-align: center;
    padding: 1rem;
    background: var(--light-gray);
    border-radius: var(--border-radius-small);
    border: 2px solid transparent;
    transition: var(--transition);
}

.result-item:hover {
    border-color: var(--primary-color);
    transform: translateY(-2px);
}

.result-label {
    font-size: 0.875rem;
    color: var(--gray);
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
}

.result-value {
    font-size: 2rem;
    font-weight: 700;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.result-grade {
    font-size: 1.5rem;
    font-weight: 700;
    padding: 0.5rem 1rem;
    border-radius: var(--border-radius-small);
    background: var(--success-gradient);
    color: var(--white);
    display: inline-block;
}

.result-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

@media (max-width: 640px) {
    .result-display {
        grid-template-columns: 1fr;
    }
    
    .result-actions {
        flex-direction: column;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
}

/* Info Card Styles */
.info-card {
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
}

.grading-info {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.grade-item {
    display: grid;
    grid-template-columns: 60px 80px 1fr;
    gap: 1rem;
    align-items: center;
    padding: 0.75rem;
    background: var(--white);
    border-radius: var(--border-radius-small);
    border-left: 4px solid var(--primary-color);
    transition: var(--transition);
}

.grade-item:hover {
    transform: translateX(5px);
    box-shadow: var(--shadow);
}

.grade-letter {
    font-weight: 700;
    font-size: 1.125rem;
    color: var(--primary-color);
}

.grade-points {
    font-weight: 600;
    color: var(--dark-gray);
    font-size: 0.875rem;
}

.grade-percent {
    color: var(--gray);
    font-size: 0.875rem;
}

/* Budget Planner Specific Styles */
.budget-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
}

.income-section,
.expenses-section {
    background: var(--white);
    padding: 2rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
}

.income-section {
    border-left: 4px solid var(--success-color);
}

.expenses-section {
    border-left: 4px solid var(--danger-color);
}

.expense-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem;
    background: var(--light-gray);
    border-radius: var(--border-radius-small);
    margin-bottom: 0.5rem;
}

.expense-category {
    font-weight: 600;
    color: var(--dark-gray);
}

.expense-amount {
    font-weight: 700;
    color: var(--danger-color);
}

.chart-container {
    background: var(--white);
    padding: 2rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    text-align: center;
}

@media (max-width: 768px) {
    .budget-section {
        grid-template-columns: 1fr;
    }
    
    .subjects-table {
        font-size: 0.875rem;
    }
    
    .subjects-table th,
    .subjects-table td {
        padding: 0.75rem 0.5rem;
    }
}

/* Timer Specific Styles */
.timer-container {
    max-width: 600px;
    margin: 0 auto;
}

.timer-display {
    text-align: center;
    padding: 3rem;
    background: var(--white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
    margin-bottom: 2rem;
}

.timer-time {
    font-size: 4rem;
    font-weight: 700;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1rem;
    font-family: 'Courier New', monospace;
}

.timer-session {
    font-size: 1.25rem;
    color: var(--gray);
    margin-bottom: 2rem;
}

.timer-controls {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.timer-settings {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.timer-stats {
    background: var(--light-gray);
    padding: 1.5rem;
    border-radius: var(--border-radius);
    text-align: center;
}

@media (max-width: 480px) {
    .timer-time {
        font-size: 3rem;
    }
    
    .timer-controls {
        flex-direction: column;
        align-items: center;
    }
    
    .timer-controls .btn {
        width: 100%;
        max-width: 200px;
    }
}

/* Animation Classes */
.fade-in {
    animation: fadeIn 0.5s ease-in;
}

.scale-in {
    animation: scaleIn 0.3s ease-out;
}

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

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Success/Error States */
.success-state {
    border-color: var(--success-color) !important;
    background-color: rgba(16, 185, 129, 0.05);
}

.error-state {
    border-color: var(--danger-color) !important;
    background-color: rgba(239, 68, 68, 0.05);
}

/* Loading States */
.loading-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--border-radius);
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #e2e8f0;
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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