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

:root {
    --primary-color: #363FBF;
    --primary-hover: #2832a8;
    --error-color: #f44336;
    --warning-color: #e65100;
    --success-color: #4CAF50;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    background-color: #f5f5f5;
    color: #333;
}

.container {
    max-width: 800px;
    margin: 2rem auto;
    padding: 2rem;
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.header {
    text-align: center;
    margin-bottom: 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.logo {
    max-width: 200px;
    height: auto;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background-color: #e0e0e0;
    border-radius: 4px;
    margin-bottom: 2rem;
}

.progress {
    height: 100%;
    background-color: var(--primary-color);
    border-radius: 4px;
    transition: width 0.3s ease;
}

h1 {
    margin-bottom: 2rem;
    color: #2c3e50;
}

h2 {
    margin: 1.5rem 0;
    color: #34495e;
}

.form-group {
    margin-bottom: 1.5rem;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

input[type="number"],
select {
    width: 100%;
    padding: 0.5rem;
    margin-bottom: 1rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1rem;
}

button {
    background-color: var(--primary-color);
    color: white;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
    transition: background-color 0.3s ease;
}

button:hover {
    background-color: var(--primary-hover);
}

.branch-detail {
    background-color: #f8f9fa;
    padding: 1rem;
    margin: 1rem 0;
    border-radius: 4px;
    border: 1px solid #dee2e6;
}

.register-types {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin: 1rem 0;
    padding: 1rem;
    background-color: #f8f9fa;
    border-radius: 4px;
    border: 1px solid #e9ecef;
}

.register-type {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.navigation-buttons {
    display: flex;
    justify-content: space-between;
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid #eee;
}

#submit-btn {
    background-color: var(--primary-color);
}

#submit-btn:hover {
    background-color: var(--primary-hover);
}

.secondary-btn {
    background-color: #f5f5f5;
    color: #333;
    border: 1px solid #ddd;
}

.secondary-btn:hover {
    background-color: #e0e0e0;
}

.section {
    margin-bottom: 2rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid #eee;
    animation: fadeIn 0.3s ease-in-out;
}

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

.wizard-header {
    margin-bottom: 2rem;
}

.step-indicator {
    text-align: center;
    color: var(--primary-color);
    font-weight: 500;
    margin-top: 0.5rem;
}

.radio-group {
    display: flex;
    gap: 2rem;
    margin: 1rem 0;
}

.radio-group label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.radio-group input[type="radio"] {
    margin: 0;
    cursor: pointer;
}

select {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1rem;
    background-color: white;
    cursor: pointer;
}

select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(54, 63, 191, 0.1);
}

.info-box {
    margin-top: 1rem;
    padding: 0.75rem;
    background-color: #fff3e0;
    border: 1px solid #ffe0b2;
    border-radius: 4px;
    color: #e65100;
    font-size: 0.9rem;
    line-height: 1.4;
}

.info-box-light {
    background-color: #f5f9ff;
    border: 1px solid #e1e8f5;
    color: var(--primary-color);
}

.info-box p {
    margin: 0;
}

.info-box ul {
    list-style-type: none;
    padding-left: 0;
    margin: 0.5rem 0;
}

.info-box li {
    padding: 0.25rem 0;
}

.datev-features {
    margin-top: 1.5rem;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-top: 1rem;
}

.feature-item {
    background-color: #fff;
    border: 1px solid #e9ecef;
    border-radius: 4px;
    padding: 1rem;
}

.feature-item h4 {
    margin: 0 0 1rem 0;
    color: #2c3e50;
    font-size: 1.1rem;
}

.checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    margin: 0.5rem 0;
    cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
    margin-top: 0.25rem;
    cursor: pointer;
}

.feature-item select {
    margin-top: 0.5rem;
}

.features-list {
    list-style-type: none;
    padding: 0;
    margin: 1rem 0;
}

.features-list li {
    padding: 0.5rem 0;
    position: relative;
    padding-left: 1.5rem;
}

.features-list li:before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--success-color);
    font-weight: bold;
}

.description {
    color: #666;
    margin: 1rem 0;
    line-height: 1.6;
}

.package-selection {
    margin-top: 2rem;
}

.package-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 1rem;
}

.package-card {
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 1.5rem;
    background-color: white;
    transition: all 0.3s ease;
    position: relative;
}

.package-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.package-card h4 {
    margin: 0;
    color: #2c3e50;
    font-size: 1.25rem;
}

.package-price {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin: 1rem 0;
    font-weight: 500;
}

.package-card h5 {
    margin: 1rem 0 0.5rem 0;
    color: #34495e;
    font-size: 1rem;
}

.package-card .features-list {
    margin-bottom: 1.5rem;
}

.premium-feature {
    color: var(--primary-color);
    font-weight: 500;
}

.premium-feature:before {
    color: var(--primary-color);
}

.package-select {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #eee;
    cursor: pointer;
}

.package-select input[type="radio"] {
    margin: 0;
    cursor: pointer;
}

.shop-config {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.extra-info {
    margin-top: 1rem;
    padding: 0.75rem;
    background-color: #fff3e0;
    border: 1px solid #ffe0b2;
    border-radius: 4px;
    color: #e65100;
    font-size: 0.9rem;
    line-height: 1.4;
}

.required {
    color: var(--error-color);
    margin-left: 2px;
}

.form-input {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(54, 63, 191, 0.1);
}

.form-input.error {
    border-color: var(--error-color);
    background-color: #fff8f8;
}

.form-input.error:focus {
    box-shadow: 0 0 0 2px rgba(244, 67, 54, 0.1);
}

.error-message {
    display: none;
    color: var(--error-color);
    font-size: 0.875rem;
    margin-top: 0.5rem;
    padding-left: 0.25rem;
}

.summary-container {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.summary-group {
    padding: 1.5rem;
    border-bottom: 1px solid #eee;
}

.summary-group:last-child {
    border-bottom: none;
}

.summary-group h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.summary-content {
    color: #333;
    line-height: 1.6;
}

.summary-content ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.summary-content li {
    margin-bottom: 0.5rem;
    padding-left: 1.5rem;
    position: relative;
}

.summary-content li::before {
    content: "•";
    color: var(--primary-color);
    position: absolute;
    left: 0;
}

.summary-note {
    margin-top: 2rem;
    padding: 1rem;
    background-color: #f5f9ff;
    border: 1px solid #e1e8f5;
    border-radius: 4px;
    color: var(--primary-color);
    text-align: center;
}

.summary-highlight {
    color: var(--primary-color);
    font-weight: 500;
}

.file-input {
    padding: 0.5rem;
    border: 2px dashed #e1e8f5;
    background-color: #f8faff;
    cursor: pointer;
}

.file-input:hover {
    border-color: var(--primary-color);
    background-color: #f5f9ff;
}

textarea.form-input {
    min-height: 100px;
    font-family: monospace;
    line-height: 1.4;
}

.receipt-text-preview {
    background: #f8faff;
    padding: 0.75rem;
    margin: 0.5rem 0;
    border: 1px solid #e1e8f5;
    border-radius: 4px;
    font-family: monospace;
    white-space: pre-wrap;
}

.form-section {
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.form-section h3 {
    margin-top: 0;
    margin-bottom: 1.5rem;
    color: var(--primary-color);
    font-size: 1.2rem;
}

.form-row {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
}

.flex-grow {
    flex-grow: 1;
}

.flex-shrink {
    flex-shrink: 0;
    width: 150px;
}

.summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-top: 1rem;
}

.summary-section {
    background: #f8faff;
    padding: 1rem;
    border-radius: 6px;
}

.summary-section h5 {
    margin-top: 0;
    margin-bottom: 0.75rem;
    color: var(--primary-color);
    font-size: 1rem;
}

.summary-section p {
    margin: 0;
    line-height: 1.5;
}

.summary-section ul {
    margin: 0;
    padding-left: 1.25rem;
}

.summary-section li {
    margin-bottom: 0.5rem;
}

.summary-section li:last-child {
    margin-bottom: 0;
}

.success-message {
    text-align: center;
    padding: 3rem 2rem;
    background-color: #f8faff;
    border-radius: 8px;
    margin: 2rem 0;
}

.success-icon {
    font-size: 4rem;
    color: var(--success-color);
    margin-bottom: 1rem;
}

.success-message h1 {
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    font-size: 2rem;
}

.success-message p {
    color: #555;
    margin-bottom: 1rem;
    font-size: 1.1rem;
    line-height: 1.6;
}

.contact-info {
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid #e1e8f5;
}

.contact-info strong {
    color: var(--primary-color);
    font-size: 1.2rem;
}

.welcome-text {
    font-size: 1.2rem;
    color: #333;
    margin-top: 0.5rem;
}

/* Redactor Editor Styles */
.redactor-box {
    border: 1px solid #e1e8f5 !important;
    border-radius: 4px !important;
    margin-bottom: 1rem;
}

.redactor-toolbar {
    border: none !important;
    background: #f8faff !important;
}

.redactor-toolbar a {
    color: #555 !important;
}

.redactor-toolbar a:hover {
    background: #e1e8f5 !important;
    color: var(--primary-color) !important;
}

.redactor-toolbar a.redactor-button-active {
    background: #e1e8f5 !important;
    color: var(--primary-color) !important;
}

.redactor-editor {
    padding: 1rem !important;
    font-family: inherit !important;
    font-size: 1rem !important;
    line-height: 1.6 !important;
}

textarea.html-editor {
    display: none;
}

/* Summary page specific styles */
.summary-only {
    max-width: 800px;
    margin: 2rem auto;
    padding: 2rem;
}

.summary-content {
    background: #fff;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.branch-summary {
    margin: 1.5rem 0;
    padding: 1.5rem;
    background: #f8f9fa;
    border-radius: 6px;
    border-left: 4px solid #0056b3;
}

.branch-summary h3 {
    color: #0056b3;
    margin-top: 0;
}

.branch-summary ul {
    list-style: none;
    padding-left: 0;
}

.branch-summary li {
    margin: 0.5rem 0;
}

.error {
    color: #dc3545;
    padding: 1rem;
    background: #f8d7da;
    border-radius: 4px;
    text-align: center;
}

.loading {
    text-align: center;
    padding: 2rem;
    color: #666;
    font-style: italic;
}

/* Modul-Box Styling */
.module-box {
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    padding: 15px;
    margin-bottom: 15px;
    background-color: #f9f9f9;
}

.module-box h3 {
    margin-top: 0;
    margin-bottom: 10px;
    color: var(--primary-color);
    font-size: 1.1rem;
    border-bottom: 1px solid #e0e0e0;
    padding-bottom: 8px;
}

.module-box p {
    margin: 5px 0;
}

.module-box p:last-child {
    margin-bottom: 0;
}

/* Tooltip Styles */
.tooltip-icon {
    display: inline-block;
    width: 16px;
    height: 16px;
    background-color: #ccc;
    color: #fff;
    border-radius: 50%;
    text-align: center;
    line-height: 16px;
    font-size: 12px;
    margin-left: 5px;
    cursor: help;
    position: relative;
}

.tooltip-icon:hover::after {
    content: attr(title);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background-color: #333;
    color: #fff;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 12px;
    white-space: normal;
    width: 200px;
    z-index: 100;
    text-align: left;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    line-height: 1.4;
}

.tooltip-icon:hover::before {
    content: '';
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    border-width: 5px;
    border-style: solid;
    border-color: transparent transparent #333 transparent;
    z-index: 100;
}

/* Loading Overlay */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    backdrop-filter: blur(4px);
}

.loading-content {
    background-color: white;
    padding: 3rem 4rem;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    text-align: center;
    max-width: 400px;
}

.spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
    margin: 0 auto 1.5rem;
}

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

.loading-text {
    font-size: 1.2rem;
    font-weight: 600;
    color: #333;
    margin-bottom: 0.5rem;
}

.loading-subtext {
    font-size: 0.9rem;
    color: #666;
    margin: 0;
}
