/*
 * The contents of this file are subject to the Netscape Public
 * License Version 1.1 (the "License"); you may not use this file
 * except in compliance with the License. You may obtain a copy of
 * the License at http://www.mozilla.org/NPL/
 *
 * Software distributed under the License is distributed on an "AS
 * IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
 * implied. See the License for the specific language governing
 * rights and limitations under the License.
 *
 * The Original Code is Mozilla Communicator client code, released
 * March 31, 1998.
 *
 * The Initial Developer of the Original Code is Netscape
 * Communications Corporation. Portions created by Netscape are
 * Copyright (C) 1998-2001 Netscape Communications Corporation. All
 * Rights Reserved.
 *
 * Contributor(s):
 *   Joe Hewitt (hewitt@netscape.com)
 */

/* ===== textfield.css ==================================================
  == Styles used by the XUL textbox element.
  ======================================================================= */

@namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul");

/* ::::: textbox ::::: */

textbox {
  cursor: text;
  margin: 2px 4px;
  background-color: #FFFFFF;
  color: #000000;
  font: inherit;
}

textbox,
textbox[readonly="true"][focused="true"] {
  border-top: 1px solid #A8B5C6;
  border-right: 1px solid #E2E8F0;
  border-bottom: 1px solid #E2E8F0;
  border-left: 1px solid #A8B5C6;
}

.textbox-internal-box,
.textarea-internal-box {
  padding: 1px 0px 1px 2px;
}

.textbox-internal-box,
.textarea-internal-box,
textbox[readonly="true"][focused="true"] > .textbox-internal-box,
textbox[readonly="true"][focused="true"] > .textarea-internal-box {
  border: 1px solid #757C8A;
}

.textbox-input,
.textbox-textarea {
  margin: 0px !important;
  border: none !important;
  padding: 0px !important;
  background-color: inherit;
  color: inherit;
  font: inherit;
}

/* ..... readonly state ..... */

textbox[readonly="true"] {
  background-color: #B4C3D4;
}

/* ..... focused state ..... */

textbox[focused="true"] {
  border: 1px solid #96A7BD;
}

textbox[focused="true"] > .textbox-internal-box,
textbox[focused="true"] > .textarea-internal-box {
  border-color: #000000;
}

/* ..... disabled state ..... */

textbox[disabled="true"] > .textbox-internal-box {
  background-color: #B4C3D4;
}

textbox[disabled="true"] {
  cursor: default !important;
  color: #85959E;
}

/* ::::: plain textbox ::::: */

textbox.plain,
textbox.plain > .textbox-internal-box,
textbox.plain > .textarea-internal-box {
  margin: 0px !important;
  border: none !important;
  padding: 0px !important;
}

/* ::::: scrollable textbox ::::: */

.scrollfield {
  margin: 1px 0px 0px 0px;
  border: none !important;
  background: inherit;
}

.scrollfield > .textbox-internal-box,
.scrollfield > .textarea-internal-box {
  margin: 0px !important;
  border: none !important;
  padding: 0px !important;
}

/* ::::: autocomplete text field ::::: */

.textbox-popup > menuitem {
  max-width: none !important;
}
