/* =================================================================== */
/*               Unified Input and Form Styles (input-styles.css)      */
/* =================================================================== */

/* --- General Text Selection --- */
/* Allow text selection in input fields */
input, textarea {
    -webkit-user-select: text;
    -ms-user-select: text;
    user-select: text;
}

/* --- Generic Form Elements (Inputs, Selects) --- */
input[type="text"],
input[type="email"],
input[type="password"],
input[type="tel"],
input[type="number"],
input[type="date"],
input[type="time"],
select,
textarea {
    display: block;
    margin: 10px 0;
    padding: 10px;
    width: 100%;
    box-sizing: border-box;
    border: 1px solid #444;
    border-radius: 6px;
    background-color: rgba(255, 255, 255, 0.05);
    color: #e4e6eb;
    font-size: 15px;
    transition: border-color 0.3s ease, background-color 0.3s ease;
}

input::placeholder,
textarea::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

input:focus,
select:focus,
textarea:focus {
    border-color: #1da1f2;
    background-color: rgba(255, 255, 255, 0.08);
    outline: none;
}

/* --- General Buttons --- */
button, .btn {
    background-color: #1da1f2;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: bold;
    width: 100%;
    margin-top: 10px;
    transition: background-color 0.3s ease, transform 0.2s ease;
}

button:hover, .btn:hover {
    background-color: #1991db;
}

button:disabled {
    background-color: #3a3b3c;
    color: #b0b3b8;
    cursor: not-allowed;
}

/* --- Form Group & Specific Containers --- */
.form-group {
    margin-bottom: 16px;
    padding: 0;
}

.password-container {
    position: relative;
    margin: 10px 0;
}

.password-input {
    padding-right: 42px; /* Space for the icon */
}

.password-toggle {
    position: absolute;
    right: 10px;
    left: auto;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #08faee;
    cursor: pointer;
    padding: 0;
    width: auto;
    margin: 0;
}

.whatsapp-container {
    display: flex;
    align-items: center;
    gap: 10px;
}

.whatsapp-container select {
    flex: 1;
    max-width: 120px;
}

.whatsapp-container input {
    flex: 2;
}

/* --- Action Icons (used in post/comment inputs) --- */
.post-action-icon,
.comment-action-icon,
.reply-action-icon {
    background: none;
    border: none;
    color: #aaa;
    cursor: pointer;
    font-size: 20px;
    padding: 5px;
    border-radius: 50%;
    transition: all 0.2s;
}

.post-action-icon {
    color: white;
    text-shadow: 0 0 3px black, 0 0 5px black, 0 0 8px black;
}

.post-action-icon:hover,
.comment-action-icon:hover,
.reply-action-icon:hover {
    color: #1da1f2;
    background-color: rgba(29, 161, 242, 0.1);
    transform: scale(1.1);
}

.hidden-input {
    display: none;
}

/* --- NEW SAWATK-ALIGNED STYLES --- */

/* Utility */
.hidden {
    display: none !important;
}

/* Attachment Options Modal */
.attachment-options-modal {
    position: absolute;
    bottom: 60px;
    right: 12px;
    background: rgba(40, 42, 45, 0.95);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 8px;
    display: flex;
    gap: 8px;
    z-index: 1002;
    box-shadow: 0 4px 12px rgba(0,0,0,0.4);
    transition: all 0.2s ease-out;
}

/* Recording UI Container */
.recording-ui-container {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 8px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
}

.recording-waveform {
    flex: 1;
    height: 30px;
    display: flex;
    align-items: center;
    gap: 2px;
    overflow: hidden;
}

.waveform-bar {
    width: 3px;
    background-color: #e42449;
    border-radius: 2px;
    animation: wave 1s infinite ease-in-out;
}

@keyframes wave {
    0%, 100% { height: 20%; }
    50% { height: 80%; }
}

.recording-timer {
    color: white;
    font-weight: bold;
    font-size: 14px;
    min-width: 45px;
    text-align: center;
}

/* Audio Preview Container */
.audio-preview-container {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 8px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
}

.play-pause-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #1da1f2;
    color: white;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 14px;
}

.time-display {
    color: #e4e6eb;
    font-size: 12px;
    min-width: 40px;
    text-align: center;
}

/* Image Preview */
.image-preview-container {
    position: relative;
    margin-top: 10px;
    width: 100%;
    max-width: 200px;
}

.image-preview-container img {
    width: 100%;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.remove-image-btn {
    position: absolute;
    top: -8px;
    right: -8px;
    background: #e42449;
    color: white;
    border: none;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.3);
}