@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Libre+Baskerville:wght@400;700&family=Great+Vibes&display=swap');

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

body {
    font-family: 'Inter', sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    padding: 20px;
    color: #333;
}

.container {
    max-width: 1600px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 350px 1fr;
    gap: 30px;
}

.sidebar {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    position: sticky;
    top: 20px;
}

.sidebar h1 {
    font-family: 'Libre Baskerville', serif;
    font-size: 24px;
    margin-bottom: 10px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.sidebar p {
    font-size: 14px;
    color: #666;
    margin-bottom: 30px;
}

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

.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    font-size: 14px;
}

.form-group select,
.form-input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    font-size: 14px;
    font-family: 'Inter', sans-serif;
    background: white;
    transition: all 0.3s ease;
}

.form-group select {
    cursor: pointer;
}

.form-group select:focus,
.form-input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
}

.form-group select:disabled {
    background: #f5f5f5;
    cursor: not-allowed;
    opacity: 0.6;
}

.input-with-button {
    display: flex;
    gap: 8px;
}

.input-with-button .form-input {
    flex: 1;
}

.btn-icon {
    padding: 12px 16px;
    background: #f5f5f5;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-icon:hover {
    background: #667eea;
    border-color: #667eea;
    transform: scale(1.05);
}

.btn {
    width: 100%;
    padding: 14px 20px;
    border: none;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-bottom: 12px;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.6);
}

.btn-secondary {
    background: white;
    color: #667eea;
    border: 2px solid #667eea;
}

.btn-secondary:hover {
    background: #667eea;
    color: white;
}

.btn-success {
    background: linear-gradient(135deg, #11998e, #38ef7d);
    color: white;
}

.btn-danger {
    background: linear-gradient(135deg, #eb3349, #f45c43);
    color: white;
}

.btn-group {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 2px solid #f0f0f0;
    text-align: center;
}

input[type="file"] {
    display: none;
}

.preview-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 20px;
    padding: 40px;
    min-height: 650px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: inset 0 2px 20px rgba(0, 0, 0, 0.2);
}

.placeholder-text {
    font-size: 18px;
    color: rgba(255, 255, 255, 0.6);
    text-align: center;
}

.placeholder-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 24px;
    padding: 60px 50px;
    text-align: center;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-width: 500px;
}

.placeholder-icon {
    font-size: 80px;
    margin-bottom: 20px;
    animation: bounce 2s infinite;
}

@keyframes bounce {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

.placeholder-title {
    font-family: 'Libre Baskerville', serif;
    font-size: 32px;
    margin-bottom: 15px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.placeholder-subtitle {
    font-size: 16px;
    color: #666;
    margin-bottom: 35px;
    line-height: 1.6;
}

.social-links {
    display: flex;
    gap: 15px;
    justify-content: center;
}

.social-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 28px;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 600;
    font-size: 15px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.social-btn.github {
    background: #24292e;
    color: white;
}

.social-btn.github:hover {
    background: #1a1e22;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(36, 41, 46, 0.4);
}

.social-btn.coffee {
    background: #FFDD00;
    color: #000;
}

.social-btn.coffee:hover {
    background: #ffcc00;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 221, 0, 0.4);
}

/* LARGE CARD - 900px for maximum visibility */
.id-card {
    /* Removed width: 100% to allow fixed width on horizontal cards */
    max-width: 900px;
    background: white;
    border-radius: 16px;
    box-shadow: 0 25px 70px rgba(0, 0, 0, 0.6);
    overflow: hidden;
    margin: 0 auto;
    position: relative;
}

.horizontal-card {
    aspect-ratio: 85.6 / 54;
    width: 700px;
    /* Fixed larger width */
    max-width: 100%;
}

/* Horizontal Card - Optimized Layout */
.horizontal-card .card-header {
    padding: 15px 25px;
}

.horizontal-card .university-logo {
    width: 55px;
    height: 55px;
}

.horizontal-card .university-name {
    font-size: 24px;
}

.horizontal-card .university-full-name {
    font-size: 12px;
}

.horizontal-card .card-content {
    padding: 15px 25px;
    align-items: center;
    /* Center vertically */
}


.horizontal-card .info-row .value {
    font-size: 13px;
}

.horizontal-card .info-row .id-number {
    font-size: 14px !important;
}

.horizontal-card .info-row .email {
    font-size: 12px !important;
}

.horizontal-card .card-footer {
    padding: 12px 25px;
}

.horizontal-card .signature-text {
    font-size: 24px;
}

.horizontal-card .signature-label {
    font-size: 9px;
}

.horizontal-card .barcode-svg {
    width: 90px;
    height: 28px;
}

.horizontal-card .barcode-number {
    font-size: 10px;
}

.vertical-card {
    aspect-ratio: 54 / 85.6;
    width: 500px;
}

.glass-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0.05));
    pointer-events: none;
    opacity: 0.4;
    mix-blend-mode: overlay;
}

.card-header {
    padding: 24px;
    color: white;
    display: flex;
    align-items: center;
    gap: 18px;
    position: relative;
    z-index: 1;
}

.university-logo {
    width: 70px;
    height: 70px;
    object-fit: contain;
    background: white;
    padding: 10px;
    border-radius: 12px;
}

.university-info {
    flex: 1;
}

.university-name {
    font-family: 'Libre Baskerville', serif;
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 5px;
}

.university-full-name {
    font-size: 14px;
    opacity: 0.95;
}

.card-content {
    padding: 30px;
    display: flex;
    gap: 25px;
    position: relative;
    z-index: 1;
}

.horizontal-card .card-content {
    flex-direction: row;
}

.vertical-card .card-content {
    flex-direction: column;
    align-items: center;
}

.student-photo {
    width: 140px;
    height: 140px;
    object-fit: cover;
    border-radius: 14px;
    border: 4px solid white;
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.2);
}

.vertical-card .student-photo {
    width: 160px;
    height: 160px;
}

.student-info {
    flex: 1;
}

.vertical-card .student-info {
    width: 100%;
}

.info-row {
    margin-bottom: 12px;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.info-row .label {
    font-size: 12px;
    font-weight: 600;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.6px;
}

.info-row .value {
    font-size: 16px;
    font-weight: 500;
    color: #333;
}

.info-row .id-number {
    font-family: 'Courier New', monospace;
    font-weight: 700;
    color: #667eea;
    font-size: 18px;
}

.info-row .email {
    font-size: 14px;
    color: #666;
}

.card-footer {
    padding: 24px 30px;
    background: rgba(0, 0, 0, 0.02);
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    z-index: 1;
}

.signature {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.signature-text {
    font-family: 'Great Vibes', cursive;
    font-size: 32px;
    color: #333;
}

.signature-label {
    font-size: 11px;
    color: #999;
    text-transform: uppercase;
}

.barcode {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
}

.barcode-svg {
    width: 110px;
    height: 35px;
}

.barcode-number {
    font-family: 'Courier New', monospace;
    font-size: 11px;
    color: #666;
}

.social-footer {
    margin-top: 25px;
    padding: 15px 25px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
}

.social-link-small {
    display: flex;
    align-items: center;
    gap: 6px;
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.social-link-small:hover {
    color: white;
    transform: translateY(-1px);
}

.social-divider {
    color: rgba(255, 255, 255, 0.4);
    font-size: 16px;
}

@media (max-width: 1200px) {
    .container {
        grid-template-columns: 1fr;
    }

    .sidebar {
        position: static;
    }
}

@media (max-width: 768px) {
    body {
        padding: 10px;
    }

    .id-card {
        max-width: 100%;
    }

    .vertical-card {
        width: 100%;
        max-width: 400px;
    }

    .social-links {
        flex-direction: column;
    }

    .social-footer {
        flex-direction: column;
        gap: 10px;
    }

    .social-divider {
        display: none;
    }
}