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

html, body {
    height: 100%;
    font-family: Arial, sans-serif;
    background-color: #f0f0f0;
}

.container {
    min-height: 100vh;
    width: 100%;
    border: 12px solid #FF7B41;
    background-color: #f5f5f5;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px 0;
}

.content-wrapper {
    width: min(920px, 94vw);
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding: 8px 4px;
    flex: 1;
}

.page-title {
    color: #FF7B41;
    text-align: center;
    font-size: 1.6rem;
}

.form-section {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.field-label {
    font-weight: bold;
    color: #333;
}

.text-input,
.text-area {
    width: 100%;
    border: 2px solid #d3d3d3;
    border-radius: 8px;
    padding: 10px 12px;
    font-size: 0.96rem;
    background-color: #fff;
    color: #111;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.text-area {
    resize: vertical;
    min-height: 220px;
    line-height: 1.45;
}

.text-input:focus,
.text-area:focus {
    border-color: #FF7B41;
    box-shadow: 0 0 0 3px rgba(255, 123, 65, 0.18);
}

.text-input.invalid,
.text-area.invalid {
    border-color: #d93025;
    box-shadow: 0 0 0 3px rgba(217, 48, 37, 0.16);
}

.error-message {
    min-height: 1.1em;
    font-size: 0.86rem;
    color: #d93025;
}

.global-error {
    text-align: center;
}

.button-row {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 8px;
}

.action-button,
.home-button,
.back-button {
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    color: #fff;
    cursor: pointer;
    font-weight: bold;
    transition: background-color 0.2s, transform 0.2s;
}

.action-button:hover,
.home-button:hover,
.back-button:hover {
    transform: translateY(-1px);
}

.usage-button,
.reset-button {
    background-color: #6f6f6f;
}

.usage-button:hover,
.reset-button:hover {
    background-color: #545454;
}

.export-button,
.home-button,
.back-button,
.close-overlay-button {
    background-color: #FF7B41;
}

.export-button:hover,
.home-button:hover,
.back-button:hover,
.close-overlay-button:hover {
    background-color: #E66A30;
}

.footer-buttons {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: auto;
    padding-bottom: 15px;
}

.footer {
    margin-top: auto;
    font-size: 0.75rem;
    color: #888;
    padding-top: 14px;
}

.overlay {
    position: fixed;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.35);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 14px;
}

.overlay.hidden {
    display: none;
}

.overlay-card {
    width: min(560px, 94vw);
    background-color: #fff;
    border-radius: 10px;
    padding: 18px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.overlay-card h2 {
    color: #FF7B41;
}

.overlay-card ol {
    padding-left: 20px;
    line-height: 1.6;
    color: #222;
}

@media (max-width: 640px) {
    .page-title {
        font-size: 1.35rem;
    }

    .button-row {
        gap: 8px;
    }

    .action-button,
    .home-button,
    .back-button {
        width: 100%;
    }
}
