:root {
    --primary-color: #facb00;
    --contrast-color: #000000;
    --text-color: #333333;
    --background-color: #FFFFFF;
    --hover-color: #ffdf4d;
    --border-color: #DDDDDD;
    --shadow-color: rgba(0, 0, 0, 0.08);
    --glow-color: rgba(250, 203, 0, 0.3);
}

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

html, body {
    height: 100%;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--primary-color);
    color: var(--text-color);
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 100vh;
}

.container {
    width: 100%;
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    flex-grow: 1;
    position: relative;
    padding-bottom: 70px;
}

header {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px 0;
    margin-bottom: 10px;
    width: 100%;
}

.logo {
    max-width: 100px;
    height: auto;
    transition: transform 0.3s ease;
}

.logo:hover {
    transform: scale(1.05);
}

main {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    background-color: var(--background-color);
    border-radius: 12px;
    padding: 40px;
    box-shadow: 0 8px 30px var(--shadow-color);
    margin: 20px auto;
    width: 100%;
    max-width: 800px;
}

.home-content {
    max-width: 800px;
}

.impressum-content {
    text-align: left;
    max-width: 800px;
    padding-bottom: 30px;
}

.legal-section {
    margin-bottom: 30px;
    width: 100%;
}

.legal-section h2 {
    font-size: 1.4rem;
    margin-bottom: 15px;
    color: var(--contrast-color);
    border-bottom: 1px solid #eee;
    padding-bottom: 8px;
}

.legal-section h3 {
    font-size: 1.2rem;
    margin: 20px 0 10px;
}

.legal-section p {
    margin-bottom: 15px;
    line-height: 1.7;
}

.legal-section a {
    color: var(--contrast-color);
    text-decoration: underline;
    text-decoration-color: var(--primary-color);
    text-underline-offset: 2px;
    transition: all 0.3s ease;
}

.legal-section a:hover {
    text-decoration-thickness: 2px;
}

.back-link {
    margin-top: 30px;
    text-align: center;
    width: 100%;
}

.contact-form {
    width: 100%;
    max-width: 600px;
    margin: 20px auto;
    background-color: #f9f9f9;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
}

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

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    text-align: left;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 0 3px var(--glow-color);
}

.form-note {
    font-size: 0.9rem;
    margin-top: 15px;
    color: #666;
    text-align: center;
}

h1 {
    font-size: 2rem;
    margin-bottom: 20px;
    color: var(--contrast-color);
    font-weight: 600;
}

h2 {
    font-size: 1.6rem;
    margin: 30px 0 20px;
    color: var(--contrast-color);
    font-weight: 600;
}

h3 {
    font-size: 1.3rem;
    margin-bottom: 10px;
    color: var(--contrast-color);
    font-weight: 600;
}

p {
    margin-bottom: 30px;
    font-size: 1.1rem;
}

.youtube-channels {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin: 20px 0 40px;
    flex-wrap: wrap;
}

.channel-link {
    text-decoration: none;
    color: inherit;
}

.channel {
    display: flex;
    align-items: center;
    padding: 12px 20px;
    border-radius: 8px;
    transition: all 0.3s ease;
    font-weight: 500;
}

.channel:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.primary-channel {
    background-color: #f9f9f9;
    border: 2px solid var(--primary-color);
}

.secondary-channel {
    background-color: #f9f9f9;
    border: 2px solid #ddd;
}

.youtube-icon {
    width: 24px;
    height: 24px;
    margin-right: 10px;
}

.exercises-section {
    width: 100%;
    margin-top: 20px;
}

.exercise-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
    width: 100%;
}

.exercise-card {
    display: flex;
    align-items: center;
    background-color: #f9f9f9;
    border-radius: 8px;
    padding: 20px;
    text-decoration: none;
    color: inherit;
    text-align: left;
    transition: all 0.3s ease;
    border: 1px solid #eee;
}

.exercise-card:hover {
    background-color: #f0f0f0;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    border-color: var(--primary-color);
}

.exercise-icon {
    background-color: var(--primary-color);
    color: var(--contrast-color);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-right: 20px;
    flex-shrink: 0;
}

.matrix-icon {
    width: 60px;
    height: 60px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 500;
    padding: 0;
    overflow: visible;
}

.matrix-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    line-height: 1.3;
}

.matrix-bracket-left, .matrix-bracket-right {
    position: absolute;
    top: 15px;
    bottom: 15px;
    width: 1px;
    background-color: var(--contrast-color);
}

.matrix-bracket-left {
    left: 18px;
}

.matrix-bracket-right {
    right: 18px;
}

.matrix-bracket-left::before, .matrix-bracket-left::after,
.matrix-bracket-right::before, .matrix-bracket-right::after {
    content: "";
    position: absolute;
    height: 1px;
    width: 5px;
    background-color: var(--contrast-color);
}

.matrix-bracket-left::before {
    top: 0;
    left: 0;
}

.matrix-bracket-left::after {
    bottom: 0;
    left: 0;
}

.matrix-bracket-right::before {
    top: 0;
    right: 0;
}

.matrix-bracket-right::after {
    bottom: 0;
    right: 0;
}

.exercise-info {
    flex: 1;
}

.exercise-info h3 {
    margin-bottom: 5px;
}

.exercise-info p {
    margin-bottom: 0;
    font-size: 0.95rem;
    color: #666;
}

.btn {
    display: inline-block;
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    font-size: 1rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 0;
    background-color: rgba(255, 255, 255, 0.2);
    transition: height 0.3s ease;
    z-index: 1;
}

.btn:hover::after {
    height: 100%;
}

.btn span {
    position: relative;
    z-index: 2;
}

.primary-btn {
    background-color: var(--primary-color);
    color: var(--contrast-color);
}

.primary-btn:hover {
    box-shadow: 0 0 15px var(--glow-color);
    transform: translateY(-2px);
}

.secondary-btn {
    background-color: var(--contrast-color);
    color: var(--background-color);
}

.secondary-btn:hover {
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.2);
    transform: translateY(-2px);
}

.tertiary-btn {
    background-color: #f5f5f5;
    color: #333;
}

.tertiary-btn:hover {
    background-color: #ebebeb;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

footer {
    text-align: center;
    width: 100%;
    padding: 20px 0;
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
}

.footer-link {
    color: var(--contrast-color);
    font-size: 0.9rem;
    text-decoration: none;
    position: relative;
    transition: all 0.3s ease;
}

.footer-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1px;
    background-color: var(--contrast-color);
    transition: width 0.3s ease;
}

.footer-link:hover::after {
    width: 100%;
}

.footer-channels {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 10px;
}

.footer-channel {
    color: var(--contrast-color);
    font-size: 0.9rem;
    text-decoration: none;
    position: relative;
    transition: all 0.3s ease;
}

.footer-channel::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1px;
    background-color: var(--contrast-color);
    transition: width 0.3s ease;
}

.footer-channel:hover::after {
    width: 100%;
}

.matrix-content {
    max-width: 600px;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.matrix-container {
    margin: 40px 0;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
}

.matrix {
    position: relative;
    font-size: 1.8rem;
    font-weight: 500;
    border-spacing: 30px 15px;
    margin: 0 auto;
}

.matrix::before, .matrix::after {
    content: "";
    position: absolute;
    top: 0;
    height: 100%;
    width: 1px;
    background-color: var(--contrast-color);
}

.matrix::before {
    left: 0;
}

.matrix::after {
    right: 0;
}

.matrix td {
    padding: 10px 15px;
    text-align: center;
    min-width: 60px;
    font-family: 'Inter', sans-serif;
    font-weight: 500;
}

.input-section {
    margin: 35px 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    width: 100%;
}

.input-section label {
    font-weight: 500;
    font-size: 1.1rem;
}

#determinant-input {
    padding: 12px 15px;
    font-size: 1rem;
    border: none;
    border-radius: 8px;
    width: 200px;
    background-color: #f7f7f7;
    transition: all 0.3s ease;
    font-family: 'Inter', sans-serif;
}

#determinant-input:focus {
    outline: none;
    box-shadow: 0 0 0 3px var(--glow-color);
}

.result-section {
    margin: 25px 0;
    font-size: 1.2rem;
    font-weight: 600;
    min-height: 30px;
    transition: all 0.5s ease;
}

.correct {
    color: #28a745;
}

.wrong {
    color: #dc3545;
}

.explanation-section {
    margin: 25px 0;
    padding: 25px 30px;
    background-color: #f9f9f9;
    border-radius: 10px;
    max-width: 600px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    line-height: 1.7;
}

.visualization-section {
    margin: 30px 0;
    transition: all 0.5s ease;
}

#zero-det-video {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

#new-matrix-btn {
    margin-top: 30px;
}

#show-explanation-btn {
    margin-top: 15px;
    padding: 8px 16px;
    font-size: 0.9rem;
}

@media (max-width: 768px) {
    .container {
        padding: 15px;
        padding-bottom: 70px;
    }

    main {
        padding: 30px 20px;
    }

    h1 {
        font-size: 1.8rem;
        margin-bottom: 25px;
    }

    .exercise-card {
        padding: 15px;
    }

    .exercise-icon {
        width: 45px;
        height: 45px;
        font-size: 1.2rem;
        margin-right: 15px;
    }
    
    .matrix-icon {
        width: 55px;
        height: 55px;
        font-size: 0.75rem;
    }
    
    .matrix-bracket-left {
        left: 16px;
    }
    
    .matrix-bracket-right {
        right: 16px;
    }

    .matrix td {
        padding: 8px 12px;
        font-size: 1.5rem;
    }
    
    .legal-section h2 {
        font-size: 1.3rem;
    }
    
    .legal-section h3 {
        font-size: 1.1rem;
    }
    
    .contact-form {
        padding: 20px;
    }
}

@media (max-width: 480px) {
    .logo {
        max-width: 80px;
    }

    h1 {
        font-size: 1.6rem;
        margin-bottom: 20px;
    }

    h2 {
        font-size: 1.4rem;
    }

    .youtube-channels {
        flex-direction: column;
        gap: 10px;
    }
    
    .exercise-icon {
        width: 40px;
        height: 40px;
        font-size: 1rem;
        margin-right: 12px;
    }
    
    .matrix-icon {
        width: 50px;
        height: 50px;
        font-size: 0.7rem;
    }
    
    .matrix-bracket-left {
        left: 15px;
    }
    
    .matrix-bracket-right {
        right: 15px;
    }

    .btn {
        padding: 10px 20px;
        font-size: 0.95rem;
    }

    .input-section {
        flex-direction: column;
        align-items: center;
        margin: 25px 0;
    }

    #determinant-input {
        width: 100%;
    }

    .matrix {
        font-size: 1.5rem;
        border-spacing: 20px 10px;
    }

    .matrix td {
        padding: 8px 10px;
        min-width: 50px;
    }
    
    .explanation-section {
        padding: 20px;
    }
    
    .impressum-content {
        padding: 20px 10px;
    }
    
    .legal-section p {
        font-size: 0.95rem;
    }
} 