@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&display=swap');

:root {
    --bg-color: #ffffff;
    --text-primary: #202124;
    --text-secondary: #5f6368;
    --accent-color: #188038; /* Green from screenshot */
    --danger-color: #d93025;
    --divider: #e0e0e0;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
    -webkit-tap-highlight-color: transparent;
}

html, body {
    overflow-x: hidden;
    width: 100%;
}

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    user-select: none;
    -webkit-user-select: none;
}
input, textarea {
    user-select: auto;
    -webkit-user-select: auto;
}

.container {
    width: 100%;
    max-width: 600px;
    margin: 70px auto 0 auto;
    flex: 1;
    position: relative;
    padding-bottom: 80px; /* Space for FAB */
}

/* Header Navbar */
nav {
    padding: 1rem 1.5rem;
    background: var(--bg-color);
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 50;
}
.nav-inner {
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
}
.search-bar {
    background-color: #f1f3f4;
    border-radius: 28px;
    display: flex;
    align-items: center;
    padding: 0.25rem 0.5rem;
}
.search-bar input {
    flex: 1;
    border: none;
    background: transparent;
    outline: none;
    font-size: 1.05rem;
    color: var(--text-primary);
    padding: 0 0.5rem;
}
.search-bar input::placeholder {
    color: var(--text-secondary);
}
.brand {
    font-weight: 500;
    font-size: 1.2rem;
    color: var(--text-primary);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 1rem;
}
.nav-actions {
    display: flex;
    gap: 1rem;
}
.nav-icon {
    color: var(--text-primary);
    background: none;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 2FA List */
.account-list { 
    display: flex; 
    flex-direction: column; 
}
.account-item-wrapper {
    position: relative;
    overflow: hidden;
    border-bottom: 1px solid var(--divider);
}
.account-item-wrapper:last-child {
    border-bottom: none;
}
.account-item-bg {
    position: absolute;
    top: 0; right: 0; bottom: 0; left: 0;
    background-color: var(--danger-color);
    display: flex;
    justify-content: flex-end;
    align-items: center;
    padding-right: 1.5rem;
    z-index: 1;
}
.account-item {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    position: relative;
    z-index: 2;
    background-color: var(--bg-color);
    transition: transform 0.3s ease;
}
.account-info {
    margin-bottom: 0.5rem;
}
.account-info h3 { 
    margin: 0; 
    font-size: 1rem; 
    font-weight: 400; 
    color: var(--text-secondary);
}
.account-info p { 
    margin: 0; 
    color: var(--text-primary); 
    font-size: 1.2rem; 
}
.totp-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.totp-code {
    font-size: 2.2rem;
    font-weight: 500;
    letter-spacing: 2px;
    color: var(--accent-color);
}
.pie-timer {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: conic-gradient(var(--accent-color) var(--p, 100%), transparent 0);
}

/* FAB */
.fab-container {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 100;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    align-items: flex-end;
}
.fab {
    width: 56px;
    height: 56px;
    background: white;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    cursor: pointer;
    text-decoration: none;
    transition: transform 0.2s;
}
.fab:active {
    transform: scale(0.95);
}
.fab-mini {
    width: 48px;
    height: 48px;
    background: #3c4043;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    cursor: pointer;
    text-decoration: none;
    color: white;
    display: none; /* hidden by default */
}
.fab-icon {
    width: 32px;
    height: 32px;
}
.fab-icon line { stroke-width: 4; stroke-linecap: round; }
.color-red { stroke: #ea4335; }
.color-green { stroke: #34a853; }
.color-yellow { stroke: #fbbc04; }
.color-blue { stroke: #4285f4; }

/* Forms */
.form-group { margin-bottom: 1.5rem; padding: 0 1.5rem; margin-top: 1.5rem; }
.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
}
.form-control {
    width: 100%;
    padding: 0.75rem 0;
    background: transparent;
    border: none;
    border-bottom: 2px solid var(--divider);
    color: var(--text-primary);
    font-size: 1rem;
    transition: border-color 0.3s;
}
.form-control:focus {
    outline: none;
    border-bottom-color: var(--accent-color);
}

.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border-radius: 4px;
    font-weight: 500;
    text-align: center;
    cursor: pointer;
    border: none;
    font-size: 1rem;
    text-decoration: none;
}
.btn-primary { background: var(--accent-color); color: var(--bg-color); width: calc(100% - 3rem); margin: 0 1.5rem; }
.btn-danger { color: var(--danger-color); background: none; padding: 0.5rem; }

h2 {
    padding: 1.5rem 1.5rem 0.5rem;
    font-size: 1.1rem;
    font-weight: 500;
    color: var(--text-secondary);
}

.toast {
    position: fixed;
    bottom: -100px;
    left: 16px;
    right: 16px;
    background-color: #323232;
    color: #e8eaed;
    padding: 14px 16px;
    border-radius: 4px;
    font-size: 0.95rem;
    z-index: 9999;
    transition: bottom 0.3s ease-in-out;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}
.toast.show {
    bottom: 24px;
}
