/* ===================================
   FORM GROUP - ALLGEMEIN
   =================================== */
.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: #2c3e50;
    font-size: 0.9rem;
}

/* ===================================
   FORM STYLES FOR REGISTER/LOGIN
   =================================== */

.form-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 400px;
    padding: 40px 20px;
}

.form-box {
    background: white;
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 450px;
}

.registration-form,
.login-form {
    width: 100%;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="password"] {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 0.95rem;
    box-sizing: border-box;
    transition: border-color 0.2s;
}

.form-group input:focus {
    outline: none;
    border-color: #3498db;
}

.form-group.checkbox-group {
    display: flex;
    align-items: center;
    gap: 8px;
}

.form-group.checkbox-group input[type="checkbox"] {
    width: auto;
    margin: 0;
}

.form-group.checkbox-group label {
    margin: 0;
    font-weight: normal;
    cursor: pointer;
}

/* ===================================
   FORM CONTROL - INPUT / SELECT / TEXTAREA
   =================================== */
.form-control {
    display: block;
    width: 100%;
    font-size: 0.9rem;
    line-height: 1.4;
    color: #333;
    background-color: #fff;
    border: 1px solid #ccc;
    border-radius: 4px;
    box-sizing: border-box;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.form-control:focus {
    outline: none;
    border-color: #71452b;
    box-shadow: 0 0 0 2px rgba(113, 69, 43, 0.2);
}

.form-control:disabled,
.form-control[readonly] {
    background-color: #f5f5f5;
    color: #888;
    cursor: not-allowed;
}

input[type="number"].form-control {
    display: block;
    width: 150px;
    font-size: 0.9rem;
    line-height: 1.4;
    color: #333;
    background-color: #fff;
    border: 1px solid #ccc;
    border-radius: 4px;
    box-sizing: border-box;
    transition: border-color 0.2s, box-shadow 0.2s;
}


/* ===================================
   FORM ROW - HORIZONTAL LAYOUT
   =================================== */
.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 15px;
    margin-bottom: 15px;
}

.form-row .form-group {
    margin-bottom: 0;
}

/* Generic form row for horizontal layout (optional) */
.form-row .form-group {
    flex: 1 1 220px;
    min-width: 220px;
    margin-bottom: 0;
}

.form-box .btn {
    width: 100%;
    padding: 12px;
    font-size: 16px;
    margin-top: 10px;
}

.form-footer {
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid #eee;
    text-align: center;
}

.form-footer p {
    margin: 10px 0;
    font-size: 0.9rem;
    color: #666;
}

.form-footer a {
    color: #3498db;
    text-decoration: none;
    font-weight: 600;
}

.form-footer a:hover {
    text-decoration: underline;
}

.password-rules-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    color: #666;
    font-size: 0.85rem;
}

.password-help-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #71452b;
    color: white;
    font-size: 12px;
    font-weight: bold;
    cursor: help;
    position: relative;
}

.password-help-icon:hover {
    background: #5a3622;
}

.password-help-icon::after {
    content: attr(data-tooltip);
    position: absolute;
    left: 50%;
    bottom: calc(100% + 8px);
    transform: translateX(-50%);
    background: #333;
    color: white;
    padding: 8px 12px;
    border-radius: 4px;
    white-space: normal;
    width: 300px;
    font-size: 13px;
    font-weight: normal;
    line-height: 1.4;
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
}

.password-help-icon:hover::after {
    opacity: 1;
}

.password-help-icon::before {
    content: '';
    position: absolute;
    left: 50%;
    bottom: calc(100% + 2px);
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: #333;
    opacity: 0;
    pointer-events: none;
}

.password-help-icon:hover::before {
    opacity: 1;
}

.password-input-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.password-input-row input {
    flex: 1;
}

.password-action-btn {
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #f8f8f8;
    color: #333;
    padding: 8px 10px;
    font-size: 0.85rem;
    line-height: 1;
    white-space: nowrap;
}

.password-action-btn:hover {
    background: #ececec;
}

.password-visibility-btn {
    min-width: 40px;
    padding: 8px;
}

/* Alert messages in forms */
.form-box .alert {
    margin-bottom: 20px;
}
