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

body {
    font-family: 'Roboto', 'Segoe UI', sans-serif;
    background: linear-gradient(to bottom, #f8f9fa 0%, #e8eaed 100%);
    min-height: 100vh;
    color: #202124;
    line-height: 1.6;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1rem;
}

@media (min-width: 640px) {
    .container {
        padding: 0 1.5rem;
    }
}

@media (min-width: 1024px) {
    .container {
        padding: 0 2rem;
    }
}

.header {
    position: sticky;
    top: 0;
    background: white;
    border-bottom: 1px solid #e8eaed;
    z-index: 100;
    box-shadow: 0 1px 3px rgba(60, 64, 67, 0.08);
}

.google-border {
    height: 4px;
    background: linear-gradient(90deg, #4285F4 0%, #4285F4 25%, #EA4335 25%, #EA4335 50%, #FBBC04 50%, #FBBC04 75%, #34A853 75%, #34A853 100%);
}

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

.header-brand {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.logo {
    width: 48px;
    height: 48px;
    flex-shrink: 0;
}

.badge-icon {
    font-size: 3rem;
    color: #FBBC04;
    flex-shrink: 0;
}

.brand-text {
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
}

.brand-title {
    font-size: 1.375rem;
    font-weight: 500;
    color: #202124;
    letter-spacing: -0.01em;
    line-height: 1.2;
}

.brand-subtitle {
    font-size: 0.875rem;
    color: #5f6368;
    font-weight: 500;
    margin-top: 0.25rem;
}

.brand-teachers {
    font-size: 0.8125rem;
    color: #4285F4;
    font-weight: 400;
    margin-top: 0.25rem;
}

.system-description {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem;
    background: linear-gradient(135deg, #e8f0fe 0%, #f8f9fa 100%);
    border-radius: 8px;
    margin-top: 1rem;
    margin-bottom: 1rem;
    border-left: 4px solid #4285F4;
}

.description-icon {
    font-size: 1.25rem;
    color: #4285F4;
    flex-shrink: 0;
    margin-top: 0.125rem;
}

.system-description p {
    margin: 0;
    font-size: 0.875rem;
    line-height: 1.6;
    color: #3c4043;
}

.header-meta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #5f6368;
    font-size: 0.875rem;
    padding: 0.5rem 1rem;
    background: #f8f9fa;
    border-radius: 24px;
}

.header-meta .material-icons {
    font-size: 1.125rem;
    color: #4285F4;
}

.meta-text {
    font-weight: 500;
}

@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
        padding: 0.875rem 0;
    }
    
    .badge-icon {
        font-size: 2.5rem;
    }
    
    .brand-title {
        font-size: 1.125rem;
    }
    
    .brand-subtitle {
        font-size: 0.8125rem;
    }
    
    .brand-teachers {
        font-size: 0.75rem;
    }
    
    .system-description {
        padding: 0.875rem;
        margin-top: 0.75rem;
        margin-bottom: 0.75rem;
    }
    
    .system-description p {
        font-size: 0.8125rem;
    }
    
    .header-meta {
        width: 100%;
        justify-content: center;
    }
}

.input-section {
    background: #fafafa;
    padding: 2rem 0;
    border-bottom: 1px solid #e0e0e0;
}

.input-wrapper {
    max-width: 48rem;
    margin: 0 auto;
}

.section-title {
    font-size: 1.5rem;
    font-weight: 400;
    color: #202124;
    margin-bottom: 1.5rem;
}

.alert {
    padding: 1rem 1.25rem;
    border-radius: 0.5rem;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.875rem;
}

.alert-success {
    background: #d1fae5;
    color: #065f46;
    border: 1px solid #a7f3d0;
}

.alert-error {
    background: #fee2e2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

.alert-icon {
    width: 1.25rem;
    height: 1.25rem;
    flex-shrink: 0;
}

.input-form {
    background: white;
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: 0 1px 2px rgba(60, 64, 67, 0.3), 0 2px 6px rgba(60, 64, 67, 0.15);
    border: 1px solid #e8eaed;
}

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

.form-label {
    font-size: 0.875rem;
    font-weight: 500;
    color: #374151;
}

.input-button-group {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

@media (min-width: 768px) {
    .input-button-group {
        flex-direction: row;
    }
}

.form-input {
    flex: 1;
    height: 3rem;
    padding: 0 1rem;
    border: 2px solid #e5e7eb;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    font-family: 'JetBrains Mono', monospace;
    transition: all 0.2s;
}

.form-input:focus {
    outline: none;
    border-color: #4285F4;
    box-shadow: 0 0 0 3px rgba(66, 133, 244, 0.1);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0 1.5rem;
    height: 3rem;
    border: none;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}

.btn-primary {
    background: #4285F4;
    color: white;
}

.btn-primary:hover {
    background: #1a73e8;
    transform: translateY(-1px);
    box-shadow: 0 4px 6px rgba(66, 133, 244, 0.25);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-icon {
    width: 1.25rem;
    height: 1.25rem;
}

.form-helper {
    font-size: 0.75rem;
    color: #6b7280;
}

.metrics-section {
    padding: 3rem 0;
}

.metrics-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    margin-top: 1.5rem;
}

@media (min-width: 640px) {
    .metrics-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .metrics-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.metric-card {
    background: white;
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: 0 1px 2px rgba(60, 64, 67, 0.3), 0 2px 6px rgba(60, 64, 67, 0.15);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid #e8eaed;
}

.metric-card:hover {
    box-shadow: 0 4px 8px rgba(60, 64, 67, 0.3), 0 8px 16px rgba(60, 64, 67, 0.15);
    transform: translateY(-2px);
}

.metric-icon {
    width: 2.5rem;
    height: 2.5rem;
    margin-bottom: 1rem;
}

.metric-icon.blue { color: #4285F4; }
.metric-icon.green { color: #34A853; }
.metric-icon.yellow { color: #FBBC04; }
.metric-icon.red { color: #EA4335; }

.metric-value {
    font-size: 2.25rem;
    font-weight: 400;
    color: #202124;
    line-height: 1;
}

.metric-label {
    font-size: 0.875rem;
    color: #5f6368;
    margin-top: 0.5rem;
    font-weight: 400;
}

.filter-section {
    background: white;
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: 0 1px 2px rgba(60, 64, 67, 0.3), 0 2px 6px rgba(60, 64, 67, 0.15);
    margin-bottom: 2rem;
    border: 1px solid #e8eaed;
}

.charts-section {
    padding: 2rem 0 3rem;
    background: white;
    margin: 2rem 0;
    border-radius: 12px;
}

.charts-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    margin-top: 1.5rem;
}

@media (min-width: 1024px) {
    .charts-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.chart-card {
    background: #fafafa;
    padding: 1.5rem;
    border-radius: 12px;
    border: 1px solid #e8eaed;
}

.chart-title {
    font-size: 1rem;
    font-weight: 500;
    color: #202124;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.chart-container {
    position: relative;
    height: 300px;
}

.filter-controls {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    align-items: flex-end;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    flex: 1;
    min-width: 180px;
}

@media (max-width: 640px) {
    .filter-group {
        flex: 1 1 100%;
        min-width: 100%;
    }
}

.filter-label {
    font-size: 0.75rem;
    font-weight: 500;
    color: #5f6368;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.filter-select {
    height: 2.5rem;
    padding: 0 0.75rem;
    border: 1px solid #dadce0;
    border-radius: 4px;
    font-size: 0.875rem;
    color: #202124;
    background: white;
    cursor: pointer;
    transition: border-color 0.2s;
}

.filter-select:focus {
    outline: none;
    border-color: #4285F4;
    box-shadow: 0 0 0 2px rgba(66, 133, 244, 0.1);
}

.btn-secondary {
    background: white;
    color: #5f6368;
    border: 1px solid #dadce0;
    height: 2.5rem;
    padding: 0 1rem;
}

.btn-secondary:hover {
    background: #f8f9fa;
    border-color: #5f6368;
}

.students-section {
    padding: 2rem 0 4rem;
}

.students-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    margin-top: 1.5rem;
}

@media (min-width: 768px) {
    .students-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .students-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.student-card {
    background: white;
    padding: 1.25rem;
    border-radius: 12px;
    box-shadow: 0 1px 2px rgba(60, 64, 67, 0.3), 0 2px 6px rgba(60, 64, 67, 0.15);
    text-decoration: none;
    color: inherit;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    gap: 1rem;
    border: 1px solid #e8eaed;
    position: relative;
    overflow: hidden;
}

@media (min-width: 640px) {
    .student-card {
        padding: 1.5rem;
    }
}

.student-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #4285F4, #34A853, #FBBC04, #EA4335);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.student-card:hover::before {
    opacity: 1;
}

.student-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 8px rgba(60, 64, 67, 0.3), 0 8px 16px rgba(60, 64, 67, 0.15);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
}

.student-name {
    font-size: 1.125rem;
    font-weight: 600;
    color: #1a1a1a;
    line-height: 1.4;
}

.external-link-icon {
    width: 1.25rem;
    height: 1.25rem;
    color: #9ca3af;
    flex-shrink: 0;
}

.badge-count-display {
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
}

.badge-number {
    font-size: 1.875rem;
    font-weight: 400;
    color: #4285F4;
}

.badge-label {
    font-size: 0.875rem;
    color: #5f6368;
    font-weight: 400;
}

.platform-chip {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: #e8f0fe;
    color: #1967d2;
    font-size: 0.75rem;
    font-weight: 500;
    border-radius: 16px;
    width: fit-content;
}

.platform-chip.credly {
    background: #fff4e5;
    color: #ea8600;
}

.platform-chip.google {
    background: #e8f0fe;
    color: #1967d2;
}

.card-url {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.75rem;
    color: #9ca3af;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.empty-state {
    text-align: center;
    padding: 4rem 2rem;
}

.empty-icon {
    width: 4rem;
    height: 4rem;
    color: #d1d5db;
    margin: 0 auto 1.5rem;
}

.empty-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 0.5rem;
}

.empty-text {
    font-size: 0.875rem;
    color: #6b7280;
    max-width: 28rem;
    margin: 0 auto;
}

.pagination {
    margin-top: 2rem;
}

.pagination-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.pagination-btn {
    min-width: 2.5rem;
    height: 2.5rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #dadce0;
    background: white;
    color: #5f6368;
    border-radius: 4px;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    padding: 0 0.5rem;
}

.pagination-btn:hover:not(:disabled) {
    background: #f8f9fa;
    border-color: #4285F4;
    color: #4285F4;
}

.pagination-btn.active {
    background: #4285F4;
    color: white;
    border-color: #4285F4;
}

.pagination-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.pagination-btn .material-icons {
    font-size: 1.25rem;
}

.pagination-dots {
    color: #5f6368;
    padding: 0 0.25rem;
    font-weight: 500;
}
