/* Reset i podstawowe style */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    padding: 20px;
    line-height: 1.6;
}

/* Główny kontener */
.container {
    max-width: 900px;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    backdrop-filter: blur(10px);
    animation: fadeInUp 0.6s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Header */
.header {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    padding: 40px 30px;
    text-align: center;
    color: white;
    position: relative;
    overflow: hidden;
}

.header::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    animation: rotate 20s linear infinite;
}

@keyframes rotate {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.header h1 {
    font-size: 2.8em;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    position: relative;
    z-index: 1;
}

.header p {
    font-size: 1.2em;
    opacity: 0.9;
    position: relative;
    z-index: 1;
}

/* Zawartość */
.content {
    padding: 50px 40px;
}

/* Ekran startowy */
.start-screen {
    text-align: center;
    animation: fadeIn 0.8s ease-out;
}

.start-screen h2 {
    color: #333;
    margin-bottom: 25px;
    font-size: 2em;
    font-weight: 600;
}

.start-screen p {
    color: #666;
    margin-bottom: 25px;
    font-size: 1.1em;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.dimensions-list {
    text-align: left;
    max-width: 500px;
    margin: 30px auto;
    padding: 0;
    list-style: none;
}

.dimensions-list li {
    background: #f8f9fa;
    margin: 10px 0;
    padding: 15px 20px;
    border-radius: 10px;
    border-left: 4px solid #4facfe;
    transition: transform 0.2s ease;
}

.dimensions-list li:hover {
    transform: translateX(5px);
    background: #e3f2fd;
}

/* Kontener pytań */
.question-container {
    display: none;
    animation: slideIn 0.5s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Pasek postępu */
.progress-bar {
    width: 100%;
    height: 10px;
    background: linear-gradient(90deg, #e0e0e0, #f0f0f0);
    border-radius: 5px;
    margin-bottom: 40px;
    overflow: hidden;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #4facfe, #00f2fe);
    transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 5px;
    box-shadow: 0 2px 4px rgba(79, 172, 254, 0.3);
}

/* Pytanie */
.question {
    margin-bottom: 40px;
}

.question h3 {
    color: #333;
    margin-bottom: 25px;
    font-size: 1.4em;
    line-height: 1.5;
    font-weight: 500;
}

.question-number {
    color: #4facfe;
    font-weight: bold;
    font-size: 1.1em;
}

/* Opcje odpowiedzi */
.options {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.option {
    background: #f8f9fa;
    border: 2px solid #e9ecef;
    border-radius: 15px;
    padding: 25px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    font-size: 1.05em;
}

.option::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(79, 172, 254, 0.1), transparent);
    transition: left 0.6s ease;
}

.option:hover {
    border-color: #4facfe;
    background: #fff;
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(79, 172, 254, 0.15);
}

.option:hover::before {
    left: 100%;
}

.option.selected {
    border-color: #4facfe;
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(79, 172, 254, 0.3);
}

.option.selected::before {
    display: none;
}

/* Przyciski */
.btn {
    border: none;
    padding: 15px 25px;
    border-radius: 25px;
    font-size: 1.1em;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-decoration: none;
    display: inline-block;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.6s ease;
}

.btn:hover::before {
    left: 100%;
}

.btn-primary {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(79, 172, 254, 0.3);
}

.btn-primary:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(79, 172, 254, 0.4);
}

.btn-secondary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.btn-secondary:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
}

.btn:disabled {
    background: #ccc !important;
    cursor: not-allowed;
    box-shadow: none;
    transform: none;
    color: #999;
}

.btn:disabled::before {
    display: none;
}

/* Nawigacja */
.navigation {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 40px;
    flex-wrap: wrap;
    gap: 20px;
}

.question-counter {
    font-size: 1.1em;
    font-weight: 600;
    color: #666;
    background: #f8f9fa;
    padding: 10px 20px;
    border-radius: 20px;
    border: 2px solid #e9ecef;
}

/* Ekran wyników */
.result-screen {
    display: none;
    text-align: center;
    animation: zoomIn 0.6s ease-out;
}

@keyframes zoomIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.personality-type {
    font-size: 4em;
    font-weight: bold;
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
    letter-spacing: 0.1em;
}

.type-name {
    font-size: 1.8em;
    color: #333;
    margin-bottom: 30px;
    font-weight: 600;
}

.type-description {
    background: linear-gradient(135deg, #f8f9fa 0%, #e3f2fd 100%);
    padding: 40px;
    border-radius: 20px;
    margin-bottom: 40px;
    text-align: left;
    border: 1px solid #e1f5fe;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.type-description h4 {
    color: #4facfe;
    margin-bottom: 20px;
    font-size: 1.4em;
    font-weight: 600;
}

.type-description p {
    line-height: 1.8;
    margin-bottom: 20px;
    color: #555;
    font-size: 1.05em;
}

.type-description ul {
    margin-left: 20px;
    color: #555;
}

.type-description li {
    margin-bottom: 8px;
}

/* Wymiary wyników */
.dimensions-result {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.dimension {
    background: linear-gradient(135deg, #f8f9fa 0%, #e8f5e8 100%);
    padding: 25px;
    border-radius: 15px;
    text-align: center;
    border: 2px solid #e1f5fe;
    transition: transform 0.3s ease;
}

.dimension:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.dimension-letter {
    font-size: 2.5em;
    font-weight: bold;
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 10px;
}

.dimension-name {
    font-size: 1em;
    color: #666;
    font-weight: 500;
}

.dimension-score {
    font-size: 0.9em;
    color: #888;
    margin-top: 5px;
}

/* Akcje wyników */
.result-actions {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

/* Animacje dodatkowe */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.fade-in {
    animation: fadeIn 0.5s ease-out;
}

/* Responsywność */
@media (max-width: 768px) {
    .container {
        margin: 10px;
        border-radius: 15px;
    }
    
    .content {
        padding: 30px 20px;
    }
    
    .header {
        padding: 30px 20px;
    }
    
    .header h1 {
        font-size: 2.2em;
    }
    
    .options {
        gap: 12px;
    }
    
    .option {
        padding: 20px;
        font-size: 1em;
    }
    
    .navigation {
        flex-direction: column;
        gap: 15px;
    }
    
    .personality-type {
        font-size: 3em;
    }
    
    .dimensions-result {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: 15px;
    }
    
    .type-description {
        padding: 25px;
    }
    
    .result-actions {
        flex-direction: column;
        align-items: center;
    }
    
    .dimensions-list {
        max-width: 100%;
    }
}

@media (max-width: 480px) {
    .header h1 {
        font-size: 1.8em;
    }
    
    .header p {
        font-size: 1em;
    }
    
    .start-screen h2 {
        font-size: 1.6em;
    }
    
    .personality-type {
        font-size: 2.5em;
    }
    
    .type-name {
        font-size: 1.4em;
    }
}