@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@400;500;700&display=swap');

:root {
    --primary-color: #345a8b;
    /* Google Blue */
    --primary-hover: #1557b0;
    --bg-color: #f0f2f5;
    --surface-color: #ffffff;
    --text-primary: #202124;
    --text-secondary: #5f6368;
    --border-color: #dadce0;
    --error-color: #d93025;
    --success-color: #188038;
    --shadow-1: 0 1px 3px rgba(0, 0, 0, 0.12), 0 1px 2px rgba(0, 0, 0, 0.24);
    --shadow-2: 0 3px 6px rgba(0, 0, 0, 0.16), 0 3px 6px rgba(0, 0, 0, 0.23);
    --border-radius: 8px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Roboto', -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
    background-color: var(--bg-color);
    color: var(--text-primary);
    line-height: 1.5;
    padding: 16px;
    display: flex;
    justify-content: center;
    min-height: 100vh;
}

/* Wrapper to center content like a mobile app view on desktop */
.app-container {
    width: 100%;
    max-width: 480px;
    /* Mobile width */
    margin: 0 auto;
}

.appName {
    text-align: center;
    margin-bottom: 24px;
    padding-top: 20px;
}

.appName h2 {
    color: var(--text-primary);
    font-size: 22px;
    font-weight: 500;
}

.appName p {
    color: var(--text-secondary);
    font-size: 14px;
}

/* Cards */
.card {
    background: var(--surface-color);
    border-radius: var(--border-radius);
    padding: 24px;
    box-shadow: var(--shadow-1);
    margin-bottom: 16px;
    transition: box-shadow 0.3s cubic-bezier(.25, .8, .25, 1);
}

.card:hover {
    box-shadow: var(--shadow-2);
}

.card h2 {
    font-size: 20px;
    font-weight: 400;
    margin-bottom: 24px;
    color: var(--text-primary);
    text-align: center;
}

/* Forms */
.form-section-title {
    font-size: 16px;
    color: var(--primary-color);
    font-weight: 500;
    margin-top: 16px;
    margin-bottom: 12px;
    border-bottom: 2px solid var(--border-color);
    padding-bottom: 4px;
}

.form-group {
    margin-bottom: 20px;
    position: relative;
}

label {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    color: var(--text-secondary);
    font-weight: 500;
}

input[type="text"],
input[type="date"],
input[type="email"],
input[type="password"],
input[type="number"],
select,
textarea {
    width: 100%;
    padding: 13px 15px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    /* Material standard is 4px */
    font-size: 16px;
    color: var(--text-primary);
    background-color: var(--surface-color);
    transition: border 0.2s;
    appearance: none;
    /* Remove default browser styles */
}

input:focus,
select:focus,
textarea:focus {
    border-color: var(--primary-color);
    border-width: 2px;
    padding: 12px 14px;
    /* Adjust padding to prevent layout shift from border width change */
    outline: none;
}

/* Floating label style simulation support if needed, keeping simple for now */

button {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 0 24px;
    height: 48px;
    /* Touch target */
    border-radius: 24px;
    /* Pill shape */
    font-size: 14px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    cursor: pointer;
    width: 100%;
    box-shadow: 0 2px 2px 0 rgba(0, 0, 0, 0.14), 0 1px 5px 0 rgba(0, 0, 0, 0.12), 0 3px 1px -2px rgba(0, 0, 0, 0.2);
    transition: background-color 0.2s, box-shadow 0.2s;
}

button:hover {
    background-color: var(--primary-hover);
    box-shadow: var(--shadow-2);
}

.btn-secondary {
    background-color: white;
    color: var(--primary-color);
    border: 1px solid var(--border-color);
    margin-top: 12px;
    display: block;
    line-height: 46px;
    /* Vertically center text */
    text-align: center;
    text-decoration: none;
    border-radius: 24px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-danger {
    background-color: var(--error-color);
    color: white;
}

.btn-danger:hover {
    background-color: #b92b27;
}

/* Dashboard Specifics */
.header-info {
    background: var(--surface-color);
    padding: 16px 20px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-1);
    margin-bottom: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-info h3 {
    font-size: 18px;
    font-weight: 500;
}

.header-info small {
    display: block;
    color: var(--text-secondary);
}

.logout-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
}

.members-container h4 {
    margin-bottom: 12px;
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.member-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px;
    cursor: pointer;
    /* imply clickability */
}

.member-info h4 {
    margin-bottom: 4px;
    color: var(--text-primary);
    font-size: 16px;
    font-weight: 500;
    text-transform: none;
}

.member-info p {
    font-size: 14px;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 2px;
}

.status-badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

.status-active {
    background-color: #e6f4ea;
    color: var(--success-color);
}

.status-inactive {
    background-color: #fce8e6;
    color: var(--error-color);
}

.fab-add {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background-color: var(--primary-color);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    box-shadow: 0 3px 5px -1px rgba(0, 0, 0, .2), 0 6px 10px 0 rgba(0, 0, 0, .14), 0 1px 18px 0 rgba(0, 0, 0, .12);
    text-decoration: none;
    transition: transform 0.2s;
}

.fab-add:hover {
    transform: scale(1.05);
}

/* Alerts */
.alert {
    padding: 12px 16px;
    margin-bottom: 16px;
    border-radius: 4px;
    font-size: 14px;
    display: flex;
    align-items: center;
}

.alert-error {
    background-color: #fce8e6;
    color: var(--error-color);
}

/* Toggle Switch / Checkbox replacement if needed */
.checkbox-group {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
}

/* Avatar Styles */
.member-avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
    margin-right: 16px;
    background-color: #eee;
    border: 2px solid var(--border-color);
}

.member-card-content {
    display: flex;
    align-items: center;
    width: 100%;
}

.upload-preview {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 10px;
    border: 3px solid var(--primary-color);
    background-color: #eee;
}

.upload-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 20px;
}

/* Responsive Grid for larger screens within the mobile view? */
.form-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
}